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