171 references to Assert
Microsoft.CodeAnalysis (171)
AssemblyUtilities.cs (2)
62
RoslynDebug.
Assert
(PathUtilities.IsAbsolute(assemblyPath));
63
RoslynDebug.
Assert
(dependencyFilePaths != null);
AssemblyUtilitiesCore.cs (1)
29
RoslynDebug.
Assert
(PathUtilities.IsAbsolute(filePath));
CaseInsensitiveComparison.cs (1)
359
RoslynDebug.
Assert
(value != null);
CodeAnalysisResourcesLocalizableErrorArgument.cs (1)
18
RoslynDebug.
Assert
(targetResourceId != null);
CodeGen\LocalConstantDefinition.cs (2)
26
RoslynDebug.
Assert
(!RoslynString.IsNullOrEmpty(name));
27
RoslynDebug.
Assert
(compileTimeValue != null);
CodeGen\MetadataConstant.cs (1)
19
RoslynDebug.
Assert
(type != null);
CodeGen\PermissionSetAttribute.cs (3)
40
RoslynDebug.
Assert
(resolvedPermissionSetFilePath != null);
96
RoslynDebug.
Assert
(resolver != null);
118
RoslynDebug.
Assert
(stream != null);
CodeGen\PrivateImplementationDetails.cs (7)
109
RoslynDebug.
Assert
(systemObject != null);
110
RoslynDebug.
Assert
(systemValueType != null);
497
RoslynDebug.
Assert
(x is object && y is object);
500
RoslynDebug.
Assert
(x.Name != null && y.Name != null);
623
RoslynDebug.
Assert
(name != null);
624
RoslynDebug.
Assert
(containingType != null);
625
RoslynDebug.
Assert
(type != null);
CodeGen\ReferenceDependencyWalker.cs (3)
47
RoslynDebug.
Assert
(typeReference != null);
103
RoslynDebug.
Assert
(methodReference != null);
164
RoslynDebug.
Assert
(fieldReference != null);
CodeGen\SwitchIntegralJumpTableEmitter.cs (6)
144
RoslynDebug.
Assert
(firstConstant != null);
148
RoslynDebug.
Assert
(secondConstant != null);
417
RoslynDebug.
Assert
(constant != null &&
419
RoslynDebug.
Assert
(targetLabel != null);
432
RoslynDebug.
Assert
(constant != null &&
434
RoslynDebug.
Assert
(targetLabel != null);
CodeGen\SwitchStringJumpTableEmitter.cs (4)
76
RoslynDebug.
Assert
(emitStringCondBranchDelegate != null);
174
RoslynDebug.
Assert
(stringConstant != null &&
176
RoslynDebug.
Assert
(targetLabel != null);
187
RoslynDebug.
Assert
(caseLabels != null);
Collections\ByteSequenceComparer.cs (1)
97
RoslynDebug.
Assert
(x != null);
Collections\IdentifierCollection.cs (2)
49
RoslynDebug.
Assert
(identifier != null);
95
RoslynDebug.
Assert
(identifier != null);
Collections\SmallDictionary.cs (7)
203
RoslynDebug.
Assert
(_root is object);
373
RoslynDebug.
Assert
(unbalanced.Right is object);
385
RoslynDebug.
Assert
(unbalanced.Left is object);
397
RoslynDebug.
Assert
(unbalanced.Right is object);
398
RoslynDebug.
Assert
(unbalanced.Right.Left is object);
425
RoslynDebug.
Assert
(unbalanced.Left != null);
426
RoslynDebug.
Assert
(unbalanced.Left.Right != null);
CommandLine\CommandLineArguments.cs (3)
392
RoslynDebug.
Assert
(metadataResolver != null);
427
RoslynDebug.
Assert
(metadataResolver != null);
486
RoslynDebug.
Assert
(analyzerReference is object);
CommandLine\CommandLineParser.cs (2)
29
RoslynDebug.
Assert
(messageProvider != null);
950
RoslynDebug.
Assert
(arg != null);
CommandLine\NoThrowStreamDisposer.cs (2)
36
RoslynDebug.
Assert
(_failed != null);
56
RoslynDebug.
Assert
(_failed == null);
Compilation.EmitStream.cs (9)
60
RoslynDebug.
Assert
(emitStreamProvider != null);
61
RoslynDebug.
Assert
(strongNameProvider != null || emitStreamSignKind == EmitStreamSignKind.None);
107
RoslynDebug.
Assert
(!_created);
108
RoslynDebug.
Assert
(diagnostics != null);
121
RoslynDebug.
Assert
(_strongNameProvider != null);
168
RoslynDebug.
Assert
(_created);
169
RoslynDebug.
Assert
(_emitStreamSignKind != EmitStreamSignKind.SignedWithFile || _tempInfo.HasValue);
175
RoslynDebug.
Assert
(_emitStreamSignKind == EmitStreamSignKind.SignedWithFile);
176
RoslynDebug.
Assert
(_strongNameProvider is object);
Compilation.EmitStreamProvider.cs (1)
63
RoslynDebug.
Assert
(stream != null);
Compilation\Compilation.cs (6)
84
RoslynDebug.
Assert
(!references.IsDefault);
85
RoslynDebug.
Assert
(features != null);
1816
RoslynDebug.
Assert
(EventQueue != null);
1839
RoslynDebug.
Assert
(EventQueue != null);
1863
RoslynDebug.
Assert
(incoming is object);
1872
RoslynDebug.
Assert
(incoming is object);
Compilation\LoadDirective.cs (3)
20
RoslynDebug.
Assert
((resolvedPath != null) || !diagnostics.IsEmpty);
21
RoslynDebug.
Assert
(!diagnostics.IsDefault);
22
RoslynDebug.
Assert
(diagnostics.IsEmpty || diagnostics.All(d => d.Severity == DiagnosticSeverity.Error));
ConstantValue.cs (1)
113
RoslynDebug.
Assert
(value != null);
CvtRes.cs (1)
703
RoslynDebug.
Assert
(keyValuePair.Value != null);
Diagnostic\Diagnostic.cs (2)
470
RoslynDebug.
Assert
(this.ProgrammaticSuppressionInfo == null);
471
RoslynDebug.
Assert
(programmaticSuppressionInfo != null);
Diagnostic\Diagnostic.DiagnosticWithProgrammaticSuppression.cs (3)
25
RoslynDebug.
Assert
(!originalUnsuppressedDiagnostic.IsSuppressed);
26
RoslynDebug.
Assert
(originalUnsuppressedDiagnostic.ProgrammaticSuppressionInfo == null);
27
RoslynDebug.
Assert
(programmaticSuppressionInfo != null);
Diagnostic\DiagnosticInfo.cs (1)
101
RoslynDebug.
Assert
(arg != null);
Diagnostic\DiagnosticWithInfo.cs (2)
26
RoslynDebug.
Assert
(info != null);
27
RoslynDebug.
Assert
(location != null);
Diagnostic\MetadataLocation.cs (1)
21
RoslynDebug.
Assert
(module != null);
DiagnosticAnalyzer\AnalysisContextInfo.cs (3)
101
RoslynDebug.
Assert
(_file.Value.AdditionalFile != null);
108
RoslynDebug.
Assert
(_file.HasValue);
109
RoslynDebug.
Assert
(_file.Value.SourceTree != null);
DiagnosticAnalyzer\SourceOrAdditionalFile.cs (1)
53
RoslynDebug.
Assert
(AdditionalFile != null);
EmbeddedText.cs (8)
213
RoslynDebug.
Assert
(stream != null);
214
RoslynDebug.
Assert
(stream.CanRead);
215
RoslynDebug.
Assert
(stream.CanSeek);
266
RoslynDebug.
Assert
(bytes.Array != null);
295
RoslynDebug.
Assert
(text != null);
296
RoslynDebug.
Assert
(text.CanBeEmbedded);
297
RoslynDebug.
Assert
(text.Encoding != null);
298
RoslynDebug.
Assert
(text.PrecomputedEmbeddedTextBlob.IsDefault);
Emit\EditAndContinue\SymbolChanges.cs (1)
138
RoslynDebug.
Assert
(synthesizedSymbol.Method != 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);
FileSystem\FileUtilities.cs (2)
49
RoslynDebug.
Assert
(searchPaths != null);
50
RoslynDebug.
Assert
(fileExists != null);
FileSystem\PathUtilities.cs (2)
438
RoslynDebug.
Assert
(!RoslynString.IsNullOrEmpty(root));
495
RoslynDebug.
Assert
(assemblyDisplayNameOrPath != null);
InternalUtilities\ArrayExtensions.cs (1)
158
RoslynDebug.
Assert
(comparer != null);
InternalUtilities\ConsList`1.cs (1)
111
RoslynDebug.
Assert
(_tail is object);
InternalUtilities\EnumerableExtensions.cs (1)
864
RoslynDebug.
Assert
(comparer != null);
InternalUtilities\EnumField.cs (1)
23
RoslynDebug.
Assert
(name != null);
InternalUtilities\InterlockedOperations.cs (1)
121
RoslynDebug.
Assert
((object?)value != null);
InternalUtilities\JsonWriter.cs (2)
280
RoslynDebug.
Assert
(pooledBuilder == null);
319
RoslynDebug.
Assert
(pooledBuilder is object);
InternalUtilities\MultiDictionary.cs (1)
196
RoslynDebug.
Assert
(_value is V); // Implies value != null
PEWriter\AssemblyReferenceAlias.cs (2)
27
RoslynDebug.
Assert
(name != null);
28
RoslynDebug.
Assert
(assembly != null);
PEWriter\DebugSourceDocument.cs (1)
28
RoslynDebug.
Assert
(location != null);
PEWriter\ManagedResource.cs (1)
30
RoslynDebug.
Assert
(streamProvider == null ^ fileReference == null);
PEWriter\MemberRefComparer.cs (1)
26
RoslynDebug.
Assert
(x is object && y is object);
PEWriter\MethodSpecComparer.cs (1)
26
RoslynDebug.
Assert
(x is object && y is object);
PEWriter\Miscellaneous.cs (2)
243
RoslynDebug.
Assert
(sectionBytes != null);
244
RoslynDebug.
Assert
(relocations != null);
PEWriter\ModifiedTypeReference.cs (1)
21
RoslynDebug.
Assert
(modifiedType != null);
PEWriter\SequencePoint.cs (1)
32
RoslynDebug.
Assert
(document != null);
PEWriter\SourceSpan.cs (1)
28
RoslynDebug.
Assert
(document != null);
PEWriter\UsedNamespaceOrType.cs (5)
38
RoslynDebug.
Assert
(type != null);
44
RoslynDebug.
Assert
(@namespace != null);
50
RoslynDebug.
Assert
(alias != null);
56
RoslynDebug.
Assert
(xmlNamespace != null);
57
RoslynDebug.
Assert
(prefix != null);
ResourceDescription.cs (1)
106
RoslynDebug.
Assert
(resource != null);
SourceGeneration\GeneratedCodeUtilities.cs (2)
21
RoslynDebug.
Assert
(symbol != null);
22
RoslynDebug.
Assert
(generatedCodeAttribute != null);
SpecialTypeExtensions.cs (2)
276
RoslynDebug.
Assert
(value != null);
374
RoslynDebug.
Assert
(value != null);
SpecialTypes.cs (1)
94
RoslynDebug.
Assert
(name is object);
SwitchConstantValueHelper.cs (5)
52
RoslynDebug.
Assert
(first != null);
53
RoslynDebug.
Assert
(second != null);
55
RoslynDebug.
Assert
(IsValidSwitchCaseLabelConstant(first));
56
RoslynDebug.
Assert
(IsValidSwitchCaseLabelConstant(second));
101
RoslynDebug.
Assert
(first != null && second != null);
Symbols\Attributes\AttributeDescription.cs (3)
23
RoslynDebug.
Assert
(@namespace != null);
24
RoslynDebug.
Assert
(name != null);
25
RoslynDebug.
Assert
(signatures != null);
Symbols\Attributes\AttributeUsageInfo.cs (1)
175
RoslynDebug.
Assert
(targetResourceIds != null);
Symbols\TypedConstant.cs (1)
160
RoslynDebug.
Assert
(type != null);
Syntax\GreenNode.cs (1)
169
RoslynDebug.
Assert
(node is object);
Syntax\InternalSyntax\SyntaxDiagnosticInfoList.cs (1)
138
RoslynDebug.
Assert
(_stack is object);
Syntax\InternalSyntax\SyntaxList.cs (5)
29
RoslynDebug.
Assert
(child0 != null);
30
RoslynDebug.
Assert
(child1 != null);
48
RoslynDebug.
Assert
(child0 != null);
49
RoslynDebug.
Assert
(child1 != null);
50
RoslynDebug.
Assert
(child2 != null);
Syntax\InternalSyntax\SyntaxList`1.cs (3)
60
RoslynDebug.
Assert
(node is object);
66
RoslynDebug.
Assert
(_node is object);
112
RoslynDebug.
Assert
(_node is object);
Syntax\SyntaxNode.cs (3)
692
RoslynDebug.
Assert
(tree != null);
778
RoslynDebug.
Assert
(syntaxNode is object);
973
RoslynDebug.
Assert
(node is object);
Syntax\SyntaxNodeOrTokenListBuilder.cs (3)
42
RoslynDebug.
Assert
(innerNode is object);
77
RoslynDebug.
Assert
(item.Node is object);
83
RoslynDebug.
Assert
(item.UnderlyingNode is object);
Text\ChangedText.cs (2)
22
RoslynDebug.
Assert
(newText != null);
24
RoslynDebug.
Assert
(oldText != null);
Text\SourceText.cs (7)
292
RoslynDebug.
Assert
(stream != null);
293
RoslynDebug.
Assert
(encoding != null);
335
RoslynDebug.
Assert
(buffer != null);
336
RoslynDebug.
Assert
(encoding != null);
687
RoslynDebug.
Assert
(algorithm != null);
696
RoslynDebug.
Assert
(algorithm != null);
1220
RoslynDebug.
Assert
(source != null);
Text\StringBuilderText.cs (1)
27
RoslynDebug.
Assert
(builder != null);
Text\StringText.cs (1)
31
RoslynDebug.
Assert
(source != null);
TreeDumper.cs (3)
80
RoslynDebug.
Assert
(node != null);
81
RoslynDebug.
Assert
(indent != null);
143
RoslynDebug.
Assert
(node != null);