126 references to Assert
Microsoft.CodeAnalysis.CSharp.EditorFeatures (1)
AutomaticCompletion\AutomaticLineEnderCommandHandler_Helpers.cs (1)
421
RoslynDebug.
Assert
(!baseObjectCreationExpressionNode.NewKeyword.IsMissing);
Microsoft.CodeAnalysis.CSharp.Features (25)
ChangeSignature\CSharpChangeSignatureService.cs (1)
894
RoslynDebug.
Assert
(parameterSymbol.IsParams);
CodeRefactorings\SyncNamespace\CSharpChangeNamespaceService.cs (2)
135
RoslynDebug.
Assert
(nameRef.Parent is object);
152
RoslynDebug.
Assert
(nameRef.Parent is object);
CSharpUseConditionalExpressionHelpers.cs (1)
16
RoslynDebug.
Assert
(throwStatement.Expression != null);
CSharpUsePatternCombinatorsCodeFixProvider.cs (1)
118
RoslynDebug.
Assert
(semanticModel != null);
EditAndContinue\CSharpEditAndContinueAnalyzer.cs (18)
105
RoslynDebug.
Assert
(((PropertyDeclarationSyntax)current).Initializer != null);
118
RoslynDebug.
Assert
(current.Parent.IsKind(SyntaxKind.VariableDeclaration));
616
RoslynDebug.
Assert
(oldBody.IsKind(SyntaxKind.Block));
617
RoslynDebug.
Assert
(newBody.IsKind(SyntaxKind.Block));
618
RoslynDebug.
Assert
(newBody.Parent.IsKind(SyntaxKind.ConstructorDeclaration));
619
RoslynDebug.
Assert
(newBody.Parent is object);
1144
RoslynDebug.
Assert
(oldTokens != null);
1145
RoslynDebug.
Assert
(newTokens != null);
2050
RoslynDebug.
Assert
(node.Parent.Parent.IsKind(SyntaxKind.IndexerDeclaration));
2062
RoslynDebug.
Assert
(node.Parent.Parent.IsKind(SyntaxKind.IndexerDeclaration));
2229
RoslynDebug.
Assert
(((LocalDeclarationStatementSyntax)node.Parent!.Parent!).AwaitKeyword.IsKind(SyntaxKind.AwaitKeyword));
2260
RoslynDebug.
Assert
(oldNode != null || newNode != null);
2263
RoslynDebug.
Assert
(newNode != null || match != null);
2568
RoslynDebug.
Assert
(current.Parent is object);
2569
RoslynDebug.
Assert
(current.Parent.Kind() == SyntaxKind.TryStatement);
2656
RoslynDebug.
Assert
(tryStatement.Finally != null);
2799
RoslynDebug.
Assert
(node is object);
2800
RoslynDebug.
Assert
(node.Parent is object);
ImplementInterface\CSharpImplementExplicitlyCodeRefactoringProvider.cs (1)
106
RoslynDebug.
Assert
(node is object);
UseExpressionBody\UseExpressionBodyCodeRefactoringProvider.cs (1)
184
RoslynDebug.
Assert
(parent is object);
Microsoft.CodeAnalysis.CSharp.Workspaces (7)
Classification\Worker_DocumentationComments.cs (1)
161
RoslynDebug.
Assert
(token.Parent is object);
CSharpIndentationService.Indenter.cs (1)
223
RoslynDebug.
Assert
(
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTreeExtensions.cs\SyntaxTreeExtensions.cs (1)
238
RoslynDebug.
Assert
(trivia.HasStructure);
NewLineUserSettingFormattingRule.cs (1)
42
RoslynDebug.
Assert
(node != null);
Rename\CSharpRenameRewriterLanguageService.cs (2)
119
RoslynDebug.
Assert
(_modifiedSubSpans != null);
533
RoslynDebug.
Assert
(_speculativeModel != null);
SpacingFormattingRule.cs (1)
47
RoslynDebug.
Assert
(previousToken.Parent != null && currentToken.Parent != null);
Microsoft.CodeAnalysis.EditorFeatures (3)
Workspaces\EditorTextFactoryService.cs (3)
44
RoslynDebug.
Assert
(stream != null);
45
RoslynDebug.
Assert
(stream.CanSeek);
46
RoslynDebug.
Assert
(stream.CanRead);
Microsoft.CodeAnalysis.EditorFeatures.Text (1)
Extensions.SnapshotSourceText.cs (1)
424
RoslynDebug.
Assert
(range.HasValue);
Microsoft.CodeAnalysis.Features (27)
AbstractBuiltInCodeStyleDiagnosticAnalyzer.cs (1)
74
RoslynDebug.
Assert
(options != null);
AbstractRemoveUnnecessaryAttributeSuppressionsDiagnosticAnalyzer.cs (2)
99
RoslynDebug.
Assert
(!string.IsNullOrEmpty(targetSymbolString));
100
RoslynDebug.
Assert
(targetValueOperation != null);
CodeFixes\Configuration\ConfigurationUpdater.cs (2)
538
RoslynDebug.
Assert
(_diagnostic != null);
552
RoslynDebug.
Assert
(_categoryToBulkConfigure != null);
CodeRefactoringHelpers.cs (2)
88
RoslynDebug.
Assert
(beginningNode is object);
89
RoslynDebug.
Assert
(endNode is object);
ConvertIfToSwitch\AbstractConvertIfToSwitchCodeRefactoringProvider.Analyzer.cs (2)
91
RoslynDebug.
Assert
(_switchTargetExpression is object);
451
RoslynDebug.
Assert
(_switchTargetType is null);
Debugging\DebugLocationInfo.cs (1)
16
RoslynDebug.
Assert
(name != null);
EditAndContinue\AbstractEditAndContinueAnalyzer.cs (12)
1126
RoslynDebug.
Assert
(lazyActiveOrMatchedLambdas != null);
1134
RoslynDebug.
Assert
(newEnclosingLambdaBody != null); // matching lambda has body
1150
RoslynDebug.
Assert
(newStatementSyntax != null);
1151
RoslynDebug.
Assert
(match != null);
1168
RoslynDebug.
Assert
(oldEnclosingLambdaBody != null);
1169
RoslynDebug.
Assert
(lazyActiveOrMatchedLambdas != null);
1676
RoslynDebug.
Assert
(hasAncestor && newAncestor != null);
1760
RoslynDebug.
Assert
(newNode != null);
1765
RoslynDebug.
Assert
(oldNode != null);
4762
RoslynDebug.
Assert
(attribute.AttributeClass is object);
5248
RoslynDebug.
Assert
(newLambdaInfo.Match != null && newLambdaBody != null);
5931
RoslynDebug.
Assert
(node is object);
EditAndContinue\EditAndContinueDiagnosticUpdateSource.cs (1)
82
RoslynDebug.
Assert
(solution != null);
ExternalAccess\UnitTesting\SolutionCrawler\UnitTestingWorkCoordinator.UnitTestingWorkItem.cs (1)
158
RoslynDebug.
Assert
(DocumentId != null);
HashCodeAnalyzer.OperationDeconstructor.cs (2)
83
RoslynDebug.
Assert
(invocation.Instance is not null);
111
RoslynDebug.
Assert
(conditional.WhenFalse is not null);
SolutionCrawler\WorkCoordinator.WorkItem.cs (1)
152
RoslynDebug.
Assert
(DocumentId != null);
Microsoft.CodeAnalysis.LanguageServer.Protocol (15)
Features\Diagnostics\DocumentAnalysisExecutor.cs (8)
180
RoslynDebug.
Assert
(_compilationWithAnalyzers != null);
197
RoslynDebug.
Assert
(analyzer.IsCompilerAnalyzer());
198
RoslynDebug.
Assert
(_compilationWithAnalyzers != null);
199
RoslynDebug.
Assert
(_compilationBasedAnalyzersInAnalysisScope.Contains(analyzer));
200
RoslynDebug.
Assert
(AnalysisScope.TextDocument is Document);
220
RoslynDebug.
Assert
(_compilationWithAnalyzers != null);
221
RoslynDebug.
Assert
(_compilationBasedAnalyzersInAnalysisScope.Contains(analyzer));
253
RoslynDebug.
Assert
(_compilationWithAnalyzers != null);
Features\Diagnostics\DocumentAnalysisExecutor_Helpers.cs (1)
331
RoslynDebug.
Assert
(location.SourceTree != null);
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.ProjectState.cs (1)
63
RoslynDebug.
Assert
(lastResult.DocumentIds != null);
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.StateSet.cs (1)
95
RoslynDebug.
Assert
(set != null);
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer_IncrementalAnalyzer.cs (4)
483
RoslynDebug.
Assert
(oldAnalysisResult.DocumentIds != null);
498
RoslynDebug.
Assert
(oldAnalysisResult.DocumentIds != null);
499
RoslynDebug.
Assert
(newAnalysisResult.DocumentIds != null);
558
RoslynDebug.
Assert
(newAnalysisResult.DocumentIds != null);
Microsoft.CodeAnalysis.Remote.ServiceHub (1)
Host\SolutionAssetCache.cs (1)
27
RoslynDebug.
Assert
(Marshal.SizeOf(typeof(SharedStopwatch)) == 8);
Microsoft.CodeAnalysis.Workspaces (38)
AbstractSpeculationAnalyzer.cs (1)
1150
RoslynDebug.
Assert
(object.Equals(parameter2.ExplicitDefaultValue, 0.0));
BKTree.Builder.cs (1)
243
RoslynDebug.
Assert
(node.SpilloverEdges is null);
ConsList`1.cs (1)
111
RoslynDebug.
Assert
(_tail is object);
Diagnostics\Extensions.cs (2)
127
RoslynDebug.
Assert
(treeToAnalyze != null || additionalFileToAnalyze != null);
268
RoslynDebug.
Assert
(additionalDocumentId != null);
EncodedStringText.cs (6)
90
RoslynDebug.
Assert
(stream != null);
91
RoslynDebug.
Assert
(stream.CanRead);
134
RoslynDebug.
Assert
(data != null);
135
RoslynDebug.
Assert
(encoding != null);
196
RoslynDebug.
Assert
(stream != null);
197
RoslynDebug.
Assert
(stream.Position == 0);
EnumerableExtensions.cs (1)
742
RoslynDebug.
Assert
(comparer != null);
EnumUtilties.cs (1)
21
RoslynDebug.
Assert
(value != null);
FileUtilities.cs (2)
48
RoslynDebug.
Assert
(searchPaths != null);
49
RoslynDebug.
Assert
(fileExists != null);
GeneratedCodeUtilities.cs (2)
21
RoslynDebug.
Assert
(symbol != null);
22
RoslynDebug.
Assert
(generatedCodeAttribute != null);
IntervalTree`1.cs (1)
195
RoslynDebug.
Assert
(currentNode != null);
J\s\src\Compilers\Core\Portable\SpecialTypeExtensions.cs\SpecialTypeExtensions.cs (1)
275
RoslynDebug.
Assert
(value != null);
MultiDictionary.cs (1)
196
RoslynDebug.
Assert
(_value is V); // Implies value != null
ObjectWriter.cs (2)
822
RoslynDebug.
Assert
(instance != null);
823
RoslynDebug.
Assert
(instanceAsWritable == null || instance == instanceAsWritable);
PathUtilities.cs (2)
437
RoslynDebug.
Assert
(!RoslynString.IsNullOrEmpty(root));
494
RoslynDebug.
Assert
(assemblyDisplayNameOrPath != null);
Rename\SymbolicRenameLocations.ReferenceProcessing.cs (1)
220
RoslynDebug.
Assert
(location.IsInSource);
SymbolUsageInfo.cs (1)
64
RoslynDebug.
Assert
(TypeOrNamespaceUsageInfoOpt.HasValue);
TemporaryStorage\TemporaryStorageServiceFactory.cs (2)
420
RoslynDebug.
Assert
(src != null);
421
RoslynDebug.
Assert
(length >= 0);
TextLineExtensions.cs (1)
70
RoslynDebug.
Assert
(text is object);
TokenData.cs (1)
99
RoslynDebug.
Assert
(commonRoot != null);
Workspace\Solution\Document.cs (1)
409
RoslynDebug.
Assert
(oldTree is object);
Workspace\Solution\DocumentState.cs (3)
560
RoslynDebug.
Assert
(_treeSource != null);
617
RoslynDebug.
Assert
(_treeSource != null);
629
RoslynDebug.
Assert
(_treeSource != null);
Workspace\Solution\ProjectDependencyGraph.cs (1)
454
RoslynDebug.
Assert
(referencesMap is object);
Workspace\Solution\SolutionState.CompilationTracker.cs (3)
347
RoslynDebug.
Assert
(previousScriptCompilation != null);
441
RoslynDebug.
Assert
(state.HasSuccessfullyLoaded.HasValue);
483
RoslynDebug.
Assert
(state.HasSuccessfullyLoaded.HasValue);
Microsoft.CodeAnalysis.Workspaces.MSBuild (1)
MSBuild\ProjectFile\ProjectFileInfo.cs (1)
117
RoslynDebug.
Assert
(filePath != null);
Microsoft.VisualStudio.LanguageServices (5)
Diagnostics\VisualStudioDiagnosticAnalyzerService.cs (1)
372
RoslynDebug.
Assert
(solution != null);
FindReferences\Contexts\AbstractTableDataSourceFindUsagesContext.cs (1)
151
RoslynDebug.
Assert
(_tableDataSink != null);
Snippets\AbstractSnippetInfoService.cs (1)
119
RoslynDebug.
Assert
(_expansionManager != null);
TaskList\ExternalErrorDiagnosticUpdateSource.cs (2)
388
RoslynDebug.
Assert
(item is DocumentId);
918
RoslynDebug.
Assert
(key is DocumentId or ProjectId);
Microsoft.VisualStudio.LanguageServices.CSharp (2)
CodeModel\CSharpCodeModelService.cs (2)
1674
RoslynDebug.
Assert
(attributeNode.Parent is AttributeListSyntax);
1682
RoslynDebug.
Assert
(attributeNode.Parent is AttributeListSyntax);