1238 references to IsEmpty
AnalyzerRunner (1)
DiagnosticAnalyzerRunner.cs (1)
334if (!analyzers.TryGetValue(project.Language, out var languageAnalyzers) || languageAnalyzers.IsEmpty)
ConfigurationSchemaGenerator (1)
RuntimeSource\SourceGenerators\TypeModelHelper.cs (1)
31if (!current.TypeArguments.IsEmpty)
illink (2)
ILLink.RoslynAnalyzer (5)
DataFlow\DynamicallyAccessedMembersBinder.cs (1)
387 if (!type.Interfaces.IsEmpty) {
src\tools\illink\src\ILLink.Shared\TrimAnalysis\HandleCallAction.cs (1)
1324 if (genericParameters.IsEmpty)
TrimAnalysis\MethodProxy.cs (1)
38 if (Method.TypeParameters.IsEmpty)
TrimAnalysis\TrimAnalysisMethodCallPattern.cs (1)
34 if (arguments.IsEmpty) {
TrimAnalysis\TypeProxy.cs (1)
17 namedType.TypeParameters.IsEmpty)
Microsoft.Analyzers.Extra (1)
CallAnalysis\Split.cs (1)
18if (memExt == null || memExt.GetMembers("Split").IsEmpty)
Microsoft.Analyzers.Extra.Tests (1)
Resources\RoslynTestUtils.cs (1)
336if (diags.IsEmpty)
Microsoft.Analyzers.Local.Tests (1)
Resources\RoslynTestUtils.cs (1)
337if (diags.IsEmpty)
Microsoft.AspNetCore.App.Analyzers (9)
Mvc\DetectAmbiguousActionRoutes.cs (2)
234if (httpMethods1.IsEmpty || httpMethods2.IsEmpty)
Mvc\MvcAnalyzer.cs (2)
128if (!attribute.ConstructorArguments.IsEmpty) 172if (attribute.ConstructorArguments.IsEmpty || attribute.ApplicationSyntaxReference is null)
RouteHandlers\DetectAmbiguousRoutes.cs (2)
216if (httpMethods1.IsEmpty || httpMethods2.IsEmpty)
RouteHandlers\DisallowMvcBindArgumentsOnParameters.cs (1)
30if (!parameter.DeclaringSyntaxReferences.IsEmpty)
RouteHandlers\RouteHandlerAnalyzer.cs (1)
124if (!methodReference.Method.DeclaringSyntaxReferences.IsEmpty)
src\Shared\Roslyn\CodeAnalysisExtensions.cs (1)
185else if (invocation.TargetMethod.IsExtensionMethod && !invocation.TargetMethod.Parameters.IsEmpty)
Microsoft.AspNetCore.Mvc.Analyzers (1)
src\Shared\Roslyn\CodeAnalysisExtensions.cs (1)
185else if (invocation.TargetMethod.IsExtensionMethod && !invocation.TargetMethod.Parameters.IsEmpty)
Microsoft.AspNetCore.Mvc.Api.Analyzers (1)
src\Shared\Roslyn\CodeAnalysisExtensions.cs (1)
185else if (invocation.TargetMethod.IsExtensionMethod && !invocation.TargetMethod.Parameters.IsEmpty)
Microsoft.Build (1)
BuildCheck\Infrastructure\EditorConfig\EditorConfigGlobsMatcher.cs (1)
43if (_numberRangePairs.IsEmpty)
Microsoft.CodeAnalysis (191)
CodeGen\ILBuilder.cs (2)
1195HasDynamicLocal |= !local.DynamicTransformFlags.IsEmpty; 1204HasDynamicLocal |= !localConstant.DynamicTransformFlags.IsEmpty;
CodeGen\SwitchIntegralJumpTableEmitter.cs (1)
100Debug.Assert(!_sortedCaseLabels.IsEmpty);
Collections\ImmutableArrayExtensions.cs (4)
352if (array.IsEmpty) 370if (array.IsEmpty) 448if (self.IsEmpty) 1040if (items.IsEmpty)
CommandLine\AnalyzerConfig.SectionNameMatching.cs (1)
39if (_numberRangePairs.IsEmpty)
CommandLine\CommonCompiler.cs (7)
426if (Arguments.EmbeddedFiles.IsEmpty) 488if (arguments.EmbeddedFiles.IsEmpty) 1134if (!analyzers.IsEmpty || !generators.IsEmpty) 1139if (!generators.IsEmpty) 1148bool hasAnalyzerConfigs = !Arguments.AnalyzerConfigPaths.IsEmpty; 1211if (!analyzers.IsEmpty)
CommandLine\ReportAnalyzerUtil.cs (1)
114if (driverTimingInfo.GeneratorTimes.IsEmpty)
CommandLine\SarifV2ErrorLogger.cs (1)
350if (effectiveSeverities.IsEmpty)
Compilation\Compilation.cs (2)
279!options.CryptoPublicKey.IsEmpty || 3616if (locations.IsEmpty)
Compilation\CompilationOptions.cs (1)
566if (!CryptoPublicKey.IsEmpty)
Compilation\LoadDirective.cs (2)
20RoslynDebug.Assert((resolvedPath != null) || !diagnostics.IsEmpty); 22RoslynDebug.Assert(diagnostics.IsEmpty || diagnostics.All(d => d.Severity == DiagnosticSeverity.Error));
DiagnosticAnalyzer\AnalysisResultBuilder.cs (8)
65if (additionalFiles.IsEmpty) 271if (!syntaxDiagnostics.IsEmpty) 277if (!semanticDiagnostics.IsEmpty) 282if (!compilationDiagnostics.IsEmpty) 334if (diagnostics.IsEmpty) 369if (diagnostics.IsEmpty) 545if (!diagnostics.IsEmpty) 575if (!diagnostics.IsEmpty)
DiagnosticAnalyzer\AnalyzerDriver.cs (18)
1027if (reportedDiagnostics.IsEmpty || 1039Debug.Assert(!reportedDiagnostics.IsEmpty); 1105if (!suppressableDiagnostics.IsEmpty) 1134if (supportedSuppressions.IsEmpty) 1202if (diagnostics.IsEmpty) 1231if (reportedDiagnostics.IsEmpty) 1780return subsetProcessedAnalyzers.IsEmpty ? EventProcessedState.NotProcessed : EventProcessedState.CreatePartiallyProcessed(subsetProcessedAnalyzers); 1821if (symbolEndActions.IsEmpty || !analysisScope.ShouldAnalyze(symbolEvent, s_getTopmostNodeForAnalysis, cancellationToken)) 1843if (!symbolEndActionsForAnalyzer.IsEmpty && 2675if (!executableCodeBlocks.IsEmpty) 2689if (!operationsToAnalyze.IsEmpty) 2776if (analyzerActions.OperationBlockStartActions.IsEmpty && 2777analyzerActions.OperationBlockActions.IsEmpty && 2778analyzerActions.OperationBlockEndActions.IsEmpty) 2797if (executableCodeBlocks.IsEmpty || !shouldExecuteCodeBlockActions) 2804if (analyzerActions.CodeBlockStartActions.IsEmpty && 2805analyzerActions.CodeBlockActions.IsEmpty && 2806analyzerActions.CodeBlockEndActions.IsEmpty)
DiagnosticAnalyzer\AnalyzerDriver.GroupedAnalyzerActions.cs (1)
37Debug.Assert(isEmpty || !GroupedActionsByAnalyzer.IsEmpty);
DiagnosticAnalyzer\AnalyzerDriver.GroupedAnalyzerActionsForAnalyzer.cs (8)
135public bool HasCodeBlockStartActions => !CodeBlockStartActions.IsEmpty; 136public bool HasOperationBlockStartActions => !OperationBlockStartActions.IsEmpty; 157if (!OperationBlockStartActions.IsEmpty || 158!OperationBlockActions.IsEmpty || 159!OperationBlockEndActions.IsEmpty || 160!CodeBlockStartActions.IsEmpty || 161!CodeBlockActions.IsEmpty || 162!CodeBlockEndActions.IsEmpty)
DiagnosticAnalyzer\AnalyzerExecutor.cs (4)
287if (reportedDiagnostics.IsEmpty) 768Debug.Assert(!executableBlocks.IsEmpty); 1006RoslynDebug.Assert(!actionsForKind.IsEmpty, $"Unexpected empty action collection in {nameof(nodeActionsByKind)}"); 1106RoslynDebug.Assert(!actionsForKind.IsEmpty, $"Unexpected empty action collection in {nameof(operationActionsByKind)}");
DiagnosticAnalyzer\AnalyzerFileReference.cs (1)
542var hasAnalyzers = !analyzers.IsEmpty;
DiagnosticAnalyzer\AnalyzerManager.AnalyzerExecutionContext.cs (1)
434Debug.Assert(!symbolEndActions.IsEmpty);
DiagnosticAnalyzer\CompilationWithAnalyzers.cs (8)
372if (!suppressors.IsEmpty) 782Debug.Assert(!symbolStartAnalyzers.IsEmpty); 788if (!otherAnalyzers.IsEmpty) 976if (pendingAnalyzers.IsEmpty) 1008if (!additionalFiles.IsEmpty) 1067if (!additionalFiles.IsEmpty) 1136if (compilationEvents.IsEmpty) 1184if (diagnostics.IsEmpty)
DiagnosticAnalyzer\DiagnosticAnalysisContextHelpers.cs (3)
124if (symbolKinds.IsEmpty) 138if (syntaxKinds.IsEmpty) 151if (operationKinds.IsEmpty)
DiagnosticAnalyzer\SuppressMessageAttributeState.cs (1)
185if (!declaredSymbols.IsEmpty)
Emit\MethodInstrumentation.cs (1)
28=> Kinds.IsEmpty;
Generated\Operations.Generated.cs (64)
4020if (!Operations.IsEmpty) return (true, 0, 0); 4036if (!Operations.IsEmpty) return (true, 0, Operations.Length - 1); 4075if (!Declarations.IsEmpty) return (true, 0, 0); 4091if (!Declarations.IsEmpty) return (true, 0, Declarations.Length - 1); 4142if (!Cases.IsEmpty) return (true, 1, 0); 4158if (!Cases.IsEmpty) return (true, 1, Cases.Length - 1); 4242if (!NextVariables.IsEmpty) return (true, 3, 0); 4258if (!NextVariables.IsEmpty) return (true, 3, NextVariables.Length - 1); 4321if (!Before.IsEmpty) return (true, 0, 0); 4332if (!AtLoopBottom.IsEmpty) return (true, 3, 0); 4348if (!AtLoopBottom.IsEmpty) return (true, 3, AtLoopBottom.Length - 1); 4359if (!Before.IsEmpty) return (true, 0, Before.Length - 1); 4440if (!NextVariables.IsEmpty) return (true, 5, 0); 4456if (!NextVariables.IsEmpty) return (true, 5, NextVariables.Length - 1); 4752if (!Catches.IsEmpty) return (true, 1, 0); 4774if (!Catches.IsEmpty) return (true, 1, Catches.Length - 1); 5035if (!Arguments.IsEmpty) return (true, 1, 0); 5051if (!Arguments.IsEmpty) return (true, 1, Arguments.Length - 1); 5186if (!Arguments.IsEmpty) return (true, 1, 0); 5202if (!Arguments.IsEmpty) return (true, 1, Arguments.Length - 1); 5253if (!Indices.IsEmpty) return (true, 1, 0); 5269if (!Indices.IsEmpty) return (true, 1, Indices.Length - 1); 5484if (!Arguments.IsEmpty) return (true, 1, 0); 5500if (!Arguments.IsEmpty) return (true, 1, Arguments.Length - 1); 5943if (!Arguments.IsEmpty) return (true, 0, 0); 5965if (!Arguments.IsEmpty) return (true, 0, Arguments.Length - 1); 6062if (!DimensionSizes.IsEmpty) return (true, 0, 0); 6084if (!DimensionSizes.IsEmpty) return (true, 0, DimensionSizes.Length - 1); 6598if (!Parts.IsEmpty) return (true, 0, 0); 6614if (!Parts.IsEmpty) return (true, 0, Parts.Length - 1); 6654if (!Initializers.IsEmpty) return (true, 0, 0); 6670if (!Initializers.IsEmpty) return (true, 0, Initializers.Length - 1); 6710if (!Initializers.IsEmpty) return (true, 0, 0); 6726if (!Initializers.IsEmpty) return (true, 0, Initializers.Length - 1); 6884if (!Elements.IsEmpty) return (true, 0, 0); 6900if (!Elements.IsEmpty) return (true, 0, Elements.Length - 1); 7727if (!ElementValues.IsEmpty) return (true, 0, 0); 7743if (!ElementValues.IsEmpty) return (true, 0, ElementValues.Length - 1); 7789if (!IgnoredArguments.IsEmpty) return (true, 0, 0); 7811if (!IgnoredArguments.IsEmpty) return (true, 0, IgnoredArguments.Length - 1); 7860if (!IgnoredDimensions.IsEmpty) return (true, 0, 0); 7865if (!Declarators.IsEmpty) return (true, 1, 0); 7887if (!Declarators.IsEmpty) return (true, 1, Declarators.Length - 1); 7892if (!IgnoredDimensions.IsEmpty) return (true, 0, IgnoredDimensions.Length - 1); 8078if (!Clauses.IsEmpty) return (true, 0, 0); 8083if (!Body.IsEmpty) return (true, 1, 0); 8099if (!Body.IsEmpty) return (true, 1, Body.Length - 1); 8104if (!Clauses.IsEmpty) return (true, 0, Clauses.Length - 1); 9123if (!Clauses.IsEmpty) return (true, 0, 0); 9139if (!Clauses.IsEmpty) return (true, 0, Clauses.Length - 1); 9186if (!DimensionSizes.IsEmpty) return (true, 1, 0); 9202if (!DimensionSizes.IsEmpty) return (true, 1, DimensionSizes.Length - 1); 9255if (!DeconstructionSubpatterns.IsEmpty) return (true, 0, 0); 9260if (!PropertySubpatterns.IsEmpty) return (true, 1, 0); 9276if (!PropertySubpatterns.IsEmpty) return (true, 1, PropertySubpatterns.Length - 1); 9281if (!DeconstructionSubpatterns.IsEmpty) return (true, 0, DeconstructionSubpatterns.Length - 1); 9345if (!Arms.IsEmpty) return (true, 1, 0); 9361if (!Arms.IsEmpty) return (true, 1, Arms.Length - 1); 10316if (!Arguments.IsEmpty) return (true, 1, 0); 10332if (!Arguments.IsEmpty) return (true, 1, Arguments.Length - 1); 10380if (!Patterns.IsEmpty) return (true, 0, 0); 10396if (!Patterns.IsEmpty) return (true, 0, Patterns.Length - 1); 10691if (!Elements.IsEmpty) return (true, 0, 0); 10707if (!Elements.IsEmpty) return (true, 0, Elements.Length - 1);
MetadataReader\MetadataReaderExtensions.cs (3)
130if (!publicKeyOrToken.IsEmpty && 143hasPublicKey = !publicKeyOrToken.IsEmpty; 150if (publicKeyOrToken.IsEmpty)
MetadataReference\MetadataImageReference.cs (1)
61if (!Properties.Aliases.IsEmpty)
NativePdbWriter\PdbWriter.cs (1)
78bool emitAllDebugInfo = isKickoffMethod || !methodBody.SequencePoints.IsEmpty ||
Operations\ControlFlowGraphBuilder.cs (11)
531r.Locals.IsEmpty && !r.HasLocalFunctions && !r.HasCaptureIds) 767if (@try.Locals.IsEmpty && !@try.HasLocalFunctions && !@try.HasCaptureIds) 1755Debug.Assert(toMerge.Locals.IsEmpty); 3652if (operation.Catches.IsEmpty && operation.Finally == null) 3671bool haveCatches = !operation.Catches.IsEmpty; 4464if (!operation.Locals.IsEmpty && operation.LoopControlVariable.Kind == OperationKind.VariableDeclarator) 6018if (initializer == null || initializer.Initializers.IsEmpty) 6371if (operation.Initializers.IsEmpty) 6393Debug.Assert(propertyReference.Arguments.IsEmpty); 7244if (!propertySymbol.Parameters.IsEmpty) 7997Debug.Assert(propertyReference.Arguments.IsEmpty);
Operations\OperationExtensions.cs (1)
319if (argumentRefKinds.IsEmpty)
Operations\OperationNodes.cs (10)
43if (!Children.IsEmpty) return (true, 0, 0); 58int.MaxValue when !Children.IsEmpty => (true, 0, Children.Length - 1), 114if (!Children.IsEmpty) return (true, 0, 0); 129int.MaxValue when !Children.IsEmpty => (true, 0, Children.Length - 1), 279if (!Arguments.IsEmpty) return (true, 0, 0); 307if (!Arguments.IsEmpty) return (true, 0, Arguments.Length - 1); 361if (!Arguments.IsEmpty) return (true, 1, 0); 381if (!Arguments.IsEmpty) return (true, 1, Arguments.Length - 1); 447if (!Arguments.IsEmpty) return (true, 1, 0); 467if (!Arguments.IsEmpty) return (true, 1, Arguments.Length - 1);
PEWriter\CustomDebugInfoWriter.cs (2)
230return !dynamicTransformFlags.IsEmpty && 249local => !local.TupleElementNames.IsEmpty,
PEWriter\MetadataWriter.cs (2)
3784Debug.Assert(signature.RefCustomModifiers.IsEmpty); 3791Debug.Assert(signature.RefCustomModifiers.IsEmpty || signature.ReturnValueIsByRef);
PEWriter\MetadataWriter.PortablePdb.cs (3)
66bool emitAllDebugInfo = isKickoffMethod || !bodyOpt.SequencePoints.IsEmpty; 490if (!dynamicFlags.IsEmpty) 501if (!tupleElementNames.IsEmpty)
ReferenceManager\CommonReferenceManager.Resolution.cs (1)
1053Debug.Assert(definitionData.Identity.PublicKeyToken.IsEmpty);
ReferenceManager\CommonReferenceManager.State.cs (1)
502if (!referenceMap[i].MergedReferences.IsEmpty)
ReferenceManager\MergedAliases.cs (1)
69if (aliases.Count == 0 ^ newAliases.IsEmpty)
RuleSet\RuleSet.cs (2)
72if (!_includes.IsEmpty) 111if (_includes.IsEmpty)
SourceGeneration\GeneratorDriver.cs (3)
216if (_state.Generators.IsEmpty) 288if (!generatorState.InputNodes.IsEmpty) 421if (generatorDiagnostics.IsEmpty)
SourceGeneration\GlobalAliases.cs (1)
31return aliasAndSymbolNames.IsEmpty ? Empty : new GlobalAliases(aliasAndSymbolNames);
SourceGeneration\Nodes\NodeStateTable.cs (1)
84public bool IsEmpty => _states.IsEmpty;
SourceGeneration\Nodes\SyntaxValueProvider_ForAttributeWithMetadataName.cs (1)
102if (!syntaxNodes.IsEmpty)
SourceGeneration\RunResults.cs (1)
91Debug.Assert(exception is null || (generatedSources.IsEmpty && diagnostics.Length == 1));
src\Dependencies\CodeAnalysis.Debugging\CustomDebugInfoReader.cs (1)
493if (importStrings.IsEmpty)
Symbols\Attributes\CustomAttributesBag.cs (1)
57_customAttributes.IsEmpty &&
Text\SourceText.cs (1)
443return !_precomputedEmbeddedTextBlob.IsEmpty;
Text\TextChangeRangeExtensions.cs (2)
120if (oldChanges.IsEmpty) 125if (newChanges.IsEmpty)
Microsoft.CodeAnalysis.CodeStyle (30)
src\Analyzers\Core\Analyzers\Helpers\DiagnosticHelper.cs (2)
116if (additionalUnnecessaryLocations.IsEmpty) 187if (additionalUnnecessaryLocations.IsEmpty)
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\AbstractRemoveUnnecessaryPragmaSuppressionsDiagnosticAnalyzer.cs (2)
524if (suppressionInfo == null || !suppressionInfo.ProgrammaticSuppressions.IsEmpty) 691if (intersect.IsEmpty)
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\SuppressMessageAttributeState.cs (1)
127return !resolvedSymbols.IsEmpty;
src\Analyzers\Core\Analyzers\RemoveUnusedMembers\AbstractRemoveUnusedMembersDiagnosticAnalyzer.cs (4)
785if (!methodSymbol.ExplicitInterfaceImplementations.IsEmpty) 835return ((IPropertySymbol)memberSymbol).ExplicitInterfaceImplementations.IsEmpty; 838return ((IEventSymbol)memberSymbol).ExplicitInterfaceImplementations.IsEmpty; 855return methodSymbol.Parameters.IsEmpty &&
src\Analyzers\Core\Analyzers\RemoveUnusedParametersAndValues\AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.BlockAnalyzer.cs (1)
87if (HasSyntaxErrors() || context.OperationBlocks.IsEmpty)
src\Analyzers\Core\Analyzers\RemoveUnusedParametersAndValues\AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.cs (1)
214!method.ExplicitOrImplicitInterfaceImplementations().IsEmpty ||
src\Analyzers\Core\Analyzers\UseCollectionInitializer\AbstractUseCollectionInitializerAnalyzer.cs (1)
87return postMatches.IsEmpty ? default : new(preMatches, postMatches);
src\Compilers\Core\Portable\Collections\ImmutableArrayExtensions.cs (4)
352if (array.IsEmpty) 370if (array.IsEmpty) 448if (self.IsEmpty) 1040if (items.IsEmpty)
src\Compilers\Core\Portable\Text\TextChangeRangeExtensions.cs (2)
120if (oldChanges.IsEmpty) 125if (newChanges.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EditorConfig\Parsing\Sections\SectionMatcher.cs (1)
302if (_numberRangePairs.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SemanticModelExtensions.cs (1)
162if (type.TypeKind == TypeKind.Array && typeArguments.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
170!branch.FinallyRegions.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (1)
353if (!basicBlock.Predecessors.IsEmpty ||
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (3)
306=> SymbolSpecifications.IsEmpty && NamingStyles.IsEmpty && NamingRules.IsEmpty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.BodyLevelSymbolKey.cs (4)
23Contract.ThrowIfTrue(symbol.DeclaringSyntaxReferences.IsEmpty && symbol.Locations.IsEmpty); 62Contract.ThrowIfTrue(symbol.DeclaringSyntaxReferences.IsEmpty && symbol.Locations.IsEmpty);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\IDictionaryExtensions.cs (1)
140dictionary[key] = existingArray.IsEmpty && value.Equals(defaultArray[0]) ? defaultArray : existingArray.Add(value);
Microsoft.CodeAnalysis.CodeStyle.Fixes (6)
src\Analyzers\Core\CodeFixes\FileHeaders\AbstractFileHeaderCodeFixProvider.cs (1)
232if (diagnostics.IsEmpty)
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.State.cs (1)
174&& ContainingType.GetMembers(WellKnownMemberNames.TopLevelStatementsEntryPointMethodName).IsEmpty;
src\Analyzers\Core\CodeFixes\ImplementInterface\ImplementInterfaceGenerator_DisposePattern.cs (1)
266baseName, n => containingType.GetMembers(n).IsEmpty);
src\Analyzers\Core\CodeFixes\RemoveUnusedParametersAndValues\AbstractRemoveUnusedValuesCodeFixProvider.cs (1)
837if (originalDeclStatementsToMoveOrRemove.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\TypeInferenceService\AbstractTypeInferenceService.cs (2)
20if (result.IsEmpty && nameOpt != null) 31if (result.IsEmpty && nameOpt != null)
Microsoft.CodeAnalysis.CSharp (274)
Binder\Binder.cs (4)
852return (locals.IsEmpty) 867if (locals.IsEmpty) 883if (locals.IsEmpty && localFunctions.IsEmpty)
Binder\Binder.WithQueryLambdaParametersBinder.cs (1)
45if (path.IsEmpty)
Binder\Binder_Conversions.cs (1)
1155result = !addMethods.IsEmpty;
Binder\Binder_Crefs.cs (6)
177if (sortedSymbols.IsEmpty) 199if (sortedSymbols.IsEmpty) 247if (sortedSymbols.IsEmpty) 293if (sortedSymbols.IsEmpty) 485Debug.Assert(!symbols.IsEmpty); 671Debug.Assert(!symbols.IsEmpty);
Binder\Binder_Expressions.cs (3)
3700Debug.Assert(handlerParameterIndexes.IsEmpty); 3731if (handlerParameterIndexes.IsEmpty) 6382Debug.Assert(!boundElementInitializerExpressions.IsEmpty);
Binder\Binder_Initializers.cs (1)
48if (initializers.IsEmpty)
Binder\Binder_InterpolatedString.cs (2)
762if (partsArray.IsEmpty && partsArray.All(p => p.IsEmpty))
Binder\Binder_Lookup.cs (2)
1050if (interfaces.IsEmpty) 1099if (!baseInterfaces.IsEmpty)
Binder\Binder_Statements.cs (2)
203Debug.Assert(!declarations.IsEmpty); 2683Debug.Assert(originalUserDefinedOperators.IsEmpty, "How could overload resolution fail if a user-defined true operator was found?");
Binder\Binder_Symbols.cs (1)
1558Debug.Assert(!typeArguments.IsEmpty);
Binder\ForLoopBinder.cs (1)
111if (!locals.IsEmpty)
Binder\Imports.cs (5)
95if (!previousSubmissionUsings.IsEmpty) 149public bool IsEmpty => UsingAliases.IsEmpty && Usings.IsEmpty && ExternAliases.IsEmpty; 160if (usingAliases.IsEmpty && usings.IsEmpty && externs.IsEmpty)
Binder\InMethodBinder.cs (3)
246Debug.Assert(!locations.IsEmpty || parameter.IsImplicitlyDeclared); 327if (parameters.IsEmpty && typeParameters.IsEmpty)
Binder\PatternExplainer.cs (7)
319if (evaluations.IsEmpty && constraints.Length == 1) 371if (constraints.IsEmpty && evaluations.IsEmpty) 470constraints.IsEmpty && 498if (evaluations.IsEmpty && 523if (constraints.IsEmpty && evaluations.IsEmpty)
Binder\Semantics\Conversions\Conversion.cs (1)
153_uncommonData = conversionResult.Kind == UserDefinedConversionResultKind.NoApplicableOperators && conversionResult.Results.IsEmpty
Binder\Semantics\Conversions\UserDefinedExplicitConversions.cs (1)
226if (operators.IsEmpty)
Binder\Semantics\Conversions\UserDefinedImplicitConversions.cs (2)
539if (items.IsEmpty) 793if (items.IsEmpty)
Binder\UsingStatementBinder.cs (1)
130Debug.Assert(!declarationsOpt.IsEmpty && declarationsOpt[0].DeclaredTypeOpt != null);
BoundTree\BoundNode_Source.cs (1)
87if (statements.Length == 1 && block.Locals.IsEmpty)
BoundTree\Constructors.cs (1)
134if (!originalMethods.IsEmpty)
BoundTree\InterpolatedStringHandlerData.cs (1)
40Debug.Assert(placeholders.IsEmpty || placeholders.AsSpan()[..^1].All(item => item.ArgumentIndex != BoundInterpolatedStringArgumentPlaceholder.TrailingConstructorValidityParameter));
BoundTree\TupleBinaryOperatorInfo.cs (1)
114Debug.Assert(operators.IsEmpty || operators.Length > 1); // an empty array is used for error cases, otherwise tuples must have cardinality > 1
BoundTree\UnboundLambda.cs (4)
119if (!InferredReturnType.UseSiteDiagnostics.IsEmpty) 124if (!InferredReturnType.Dependencies.IsEmpty) 1081if (parameterTypes.IsEmpty && parameterRefKinds.IsEmpty && taskLikeReturnTypeOpt is null)
CodeGen\EmitExpression.cs (5)
441((TypeParameterSymbol)receiverType).EffectiveInterfacesNoUseSiteDiagnostics.IsEmpty) || // This could be a nullable value type, which must be copied in order to not mutate the original value 871if (sequence.Locals.IsEmpty) 886if (sequence.Locals.IsEmpty) 905if (sequence.Locals.IsEmpty) 926if (sequence.Locals.IsEmpty)
CodeGen\EmitStatement.cs (4)
741var hasLocals = !block.Locals.IsEmpty; 753DefineLocal(local, !declaringReferences.IsEmpty ? (CSharpSyntaxNode)declaringReferences[0].GetSyntax() : block.Syntax); 794Debug.Assert(!block.Locals.IsEmpty); 1117var localSyntax = !declaringReferences.IsEmpty ? (CSharpSyntaxNode)declaringReferences[0].GetSyntax() : catchBlock.Syntax;
CodeGen\Optimizer.cs (1)
2263if (receiverOpt is BoundTypeExpression { AliasOpt: null, BoundContainingTypeOpt: null, BoundDimensionsOpt: { IsEmpty: true }, Type: { TypeKind: TypeKind.TypeParameter } } typeExpression)
Compilation\CSharpCompilation.cs (3)
1571if (usingsFromoptions.UsingNamespacesOrTypes.IsEmpty) 1575else if (previousSubmissionImports.IsEmpty) 3005Debug.Assert(!loadDirectives.IsEmpty);
Compilation\SyntaxAndDeclarationManager.cs (5)
395Debug.Assert(!oldLoadDirectives.IsEmpty); 418Debug.Assert(!loadDirectives.IsEmpty); 448Debug.Assert(!nestedLoadDirectives.IsEmpty); 573Debug.Assert(!oldLoadDirectives.IsEmpty); 687Debug.Assert(!loadDirectives.IsEmpty);
Compilation\SyntaxTreeSemanticModel.cs (1)
240else if (!info.CandidateSymbols.IsEmpty)
Compiler\ClsComplianceChecker.cs (3)
555System.Diagnostics.Debug.Assert(typeParameters.IsEmpty || IsTrue(GetDeclaredOrInheritedCompliance(context)), "Only call on compliant symbols"); 574System.Diagnostics.Debug.Assert(parameters.IsEmpty || IsTrue(GetDeclaredOrInheritedCompliance(context)), "Only call on compliant symbols"); 676if (parameters.IsEmpty) return;
Compiler\DocumentationCommentCompiler.cs (2)
304if (docCommentNodes.IsEmpty) 1164if (referencedSymbols.IsEmpty)
Compiler\DocumentationCommentCompiler.IncludeElementExpander.cs (1)
83if (sourceIncludeElementNodes.IsEmpty)
Compiler\MethodCompiler.cs (4)
290Debug.Assert(codeCoverageSpans.IsEmpty); 590if (containingType.StaticConstructors.IsEmpty) 1269Debug.Assert(initializerCodeCoverageSpans.IsEmpty); 1874Debug.Assert(constructor.Locals.IsEmpty);
Declarations\MergedNamespaceDeclaration.cs (1)
23: base(declarations.IsEmpty ? string.Empty : declarations[0].Name)
Emitter\EditAndContinue\CSharpSymbolMatcher.cs (8)
569Debug.Assert(type.ElementTypeWithAnnotations.CustomModifiers.IsEmpty); 570Debug.Assert(other.ElementTypeWithAnnotations.CustomModifiers.IsEmpty); 626Debug.Assert(type.TypeArgumentsWithAnnotationsNoUseSiteDiagnostics.All(t => t.CustomModifiers.IsEmpty)); 627Debug.Assert(other.TypeArgumentsWithAnnotationsNoUseSiteDiagnostics.All(t => t.CustomModifiers.IsEmpty)); 664Debug.Assert(type.PointedAtTypeWithAnnotations.CustomModifiers.IsEmpty); 665Debug.Assert(other.PointedAtTypeWithAnnotations.CustomModifiers.IsEmpty); 696Debug.Assert(type.CustomModifiers.IsEmpty); 708return modifiers.IsEmpty;
Emitter\EditAndContinue\PEDeltaAssemblyBuilder.cs (1)
252Debug.Assert(EmitOptions.InstrumentationKinds.IsEmpty);
Emitter\Model\AttributeDataAdapter.cs (2)
22if (commonArgs.IsEmpty) 59if (commonArgs.IsEmpty)
Emitter\Model\ExpandedVarargsMethodReference.cs (1)
28Debug.Assert(!argListParams.IsEmpty);
Emitter\Model\GenericMethodInstanceReference.cs (1)
36Debug.Assert(arg.CustomModifiers.IsEmpty);
Emitter\Model\MethodSymbolAdapter.cs (1)
255Debug.Assert(arg.CustomModifiers.IsEmpty);
Emitter\Model\SpecializedGenericMethodInstanceReference.cs (1)
37Debug.Assert(arg.CustomModifiers.IsEmpty);
Emitter\Model\SymbolAdapter.cs (1)
120if (userDefined.IsEmpty && synthesized == null)
FlowAnalysis\AbstractFlowPass.cs (2)
2712if (node.Parts.IsEmpty) 3144if (!sideEffects.IsEmpty)
FlowAnalysis\ControlFlowPass.cs (1)
276if (node.CatchBlocks.IsEmpty)
FlowAnalysis\FlowAnalysisPass.cs (2)
56Debug.Assert(!implicitlyInitializedFields.IsEmpty); 112Debug.Assert(!implicitlyInitializedFields.IsEmpty);
FlowAnalysis\NullableWalker.cs (9)
642var exitLocation = method is SynthesizedPrimaryConstructor || method.DeclaringSyntaxReferences.IsEmpty ? null : method.TryGetFirstLocation(); 1148if (!parameters.IsEmpty) 4146if (slot >= 0 && !initializer.Initializers.IsEmpty) 6594if (node is BoundCollectionElementInitializer { AddMethod: { TypeArgumentsWithAnnotations: { IsEmpty: false } } }) 6599if (node is BoundForEachStatement { EnumeratorInfoOpt: { GetEnumeratorInfo: { Method: { TypeArgumentsWithAnnotations: { IsEmpty: false } } } } }) 7044&& !(notNullWhenTrueMembers.IsEmpty && notNullWhenFalseMembers.IsEmpty)) 7057if (members.IsEmpty) 9135Debug.Assert(handlerData.ArgumentPlaceholders.IsEmpty
Lowering\ClosureConversion\ClosureConversion.Analysis.Tree.cs (1)
717if (!locals.IsEmpty && _currentScope.BoundNode != node)
Lowering\ClosureConversion\ClosureConversion.cs (2)
964if (typeArguments.IsEmpty) 1200Debug.Assert(!node.Locals.IsEmpty);
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (1)
135Debug.Assert(block.Locals.IsEmpty);
Lowering\DiagnosticsPass_ExpressionTrees.cs (3)
567if (!lambda.GetAttributes().IsEmpty || !lambda.GetReturnTypeAttributes().IsEmpty) 584if (!reportedAttributes && !p.GetAttributes().IsEmpty)
Lowering\InitializerRewriter.cs (2)
108{ WasCompilerGenerated = !fieldInit.Locals.IsEmpty || fieldInit.WasCompilerGenerated }; 110if (!fieldInit.Locals.IsEmpty)
Lowering\Instrumentation\CodeCoverageInstrumenter.cs (1)
180if (dynamicAnalysisSpans.IsEmpty)
Lowering\IteratorRewriter\IteratorMethodToStateMachineRewriter.cs (1)
375Debug.Assert(node.CatchBlocks.IsEmpty, "try with yields must have no catches");
Lowering\LocalRewriter\DelegateCacheContainer.cs (2)
69var fieldType = TypeParameters.IsEmpty ? delegateType : TypeMap.SubstituteType(delegateType).Type; 75if (!TypeParameters.IsEmpty)
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (1)
623if (cases.IsEmpty)
Lowering\LocalRewriter\LocalRewriter_Call.cs (3)
394Debug.Assert(invokedAsExtensionMethod && !arguments.IsEmpty); 724if (arguments.IsEmpty) 1197Debug.Assert(!argumentRefKindsOpt.IsEmpty);
Lowering\LocalRewriter\LocalRewriter_CollectionExpression.cs (1)
69if (node.Elements.IsEmpty &&
Lowering\LocalRewriter\LocalRewriter_DoStatement.cs (1)
55if (node.Locals.IsEmpty)
Lowering\LocalRewriter\LocalRewriter_ForEachStatement.cs (1)
547Debug.Assert(methodArgumentInfo.Arguments.IsEmpty);
Lowering\LocalRewriter\LocalRewriter_ForStatement.cs (1)
179if (node.InnerLocals.IsEmpty)
Lowering\LocalRewriter\LocalRewriter_ObjectOrCollectionInitializerExpression.cs (1)
681if (!arguments.IsEmpty || propertySymbol.IsIndexedProperty)
Lowering\LocalRewriter\LocalRewriter_PatternSwitchStatement.cs (1)
147if (section.Locals.IsEmpty)
Lowering\LocalRewriter\LocalRewriter_PropertyAccess.cs (1)
82if (_inExpressionLambda && rewrittenArguments.IsEmpty)
Lowering\LocalRewriter\LocalRewriter_StringInterpolation.cs (1)
142Debug.Assert(!parts.IsEmpty);
Lowering\LocalRewriter\LocalRewriter_SwitchExpression.cs (1)
104if (arm.Locals.IsEmpty)
Lowering\LocalRewriter\LocalRewriter_UsingStatement.cs (1)
130Debug.Assert(node.Locals.IsEmpty); // TODO: This might not be a valid assumption in presence of semicolon operator.
Lowering\LocalRewriter\LocalRewriter_WhileStatement.cs (1)
115if (locals.IsEmpty)
Lowering\LocalRewriter\LoweredDynamicOperationFactory.cs (1)
697if (!synthesizedContainer.TypeParameters.IsEmpty)
Lowering\MethodToClassRewriter.cs (1)
121if (locals.IsEmpty) return locals;
Lowering\SpillSequenceSpiller.cs (1)
544Locals.IsEmpty: true,
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (1)
731Debug.Assert(!node.Locals.IsEmpty);
Lowering\StateMachineRewriter\SynthesizedStateMachineProperty.cs (1)
63get { return !_getter.Parameters.IsEmpty; }
Lowering\SynthesizedMethodBaseSymbol.cs (2)
167Debug.Assert(base.GetAttributes().IsEmpty); 175Debug.Assert(base.GetReturnTypeAttributes().IsEmpty);
Operations\CSharpOperationFactory.cs (2)
509if (!boundAttribute.NamedArguments.IsEmpty) 880if (!boundObjectInitializerMember.Arguments.IsEmpty)
SymbolDisplay\SymbolDisplayVisitor.Members.cs (3)
586if (symbol.CallingConvention != SignatureCallingConvention.Unmanaged || !conventionTypes.IsEmpty) 1040if (Format.MemberOptions.IncludesOption(SymbolDisplayMemberOptions.IncludeExplicitInterface) && !implementedMembers.IsEmpty) 1056if (this.Format.CompilerInternalOptions.IncludesOption(SymbolDisplayCompilerInternalOptions.IncludeCustomModifiers) && !customModifiers.IsEmpty)
SymbolDisplay\SymbolDisplayVisitor.Types.cs (2)
523return modifiers.Any(static m => !m.IsEmpty); 838return !typeParam.ConstraintTypes.IsEmpty || typeParam.HasConstructorConstraint ||
SymbolDisplay\SymbolDisplayVisitor_Minimal.cs (1)
242if (this.IsMinimizing && !symbol.Locations.IsEmpty)
Symbols\AliasSymbol.cs (1)
57Debug.Assert(locations.Length == 1 || (locations.IsEmpty && aliasName == "global")); // It looks like equality implementation depends on this condition.
Symbols\ArrayTypeSymbol.cs (1)
639Debug.Assert(lowerBounds.IsDefaultOrEmpty || (!lowerBounds.IsEmpty && (lowerBounds.Length != rank || !lowerBounds.All(b => b == 0))));
Symbols\ConstraintsHelper.cs (1)
366if (clauses.All(clause => clause.ConstraintTypes.IsEmpty))
Symbols\ErrorTypeSymbol.cs (1)
70if (!CandidateSymbols.IsEmpty)
Symbols\ExtendedErrorTypeSymbol.cs (3)
79Debug.Assert(candidateSymbols.IsEmpty || resultKind != LookupResultKind.Viable, "Shouldn't use LookupResultKind.Viable with candidate symbols"); 90var candidate = candidateSymbols.IsEmpty ? null : candidateSymbols[0] as ErrorTypeSymbol; 91return ((object?)candidate != null && !candidate.CandidateSymbols.IsEmpty) ? candidate.CandidateSymbols : candidateSymbols;
Symbols\FunctionPointers\FunctionPointerMethodSymbol.cs (3)
607if (!Parameters.IsEmpty) 649if (modifiersToSearch.IsEmpty) 672if (modifiersToSearch.IsEmpty || CallingConvention != CallingConvention.Unmanaged)
Symbols\MemberSignatureComparer.cs (3)
593(unsubstitutedReturnType1.CustomModifiers.IsEmpty && unsubstitutedReturnType2.CustomModifiers.IsEmpty)) 618return typeParameters.IsEmpty ?
Symbols\MemberSymbolExtensions.cs (1)
27return !@params.IsEmpty && @params.Last().IsParams;
Symbols\Metadata\PE\DynamicTypeDecoder.cs (1)
46Debug.Assert(!dynamicTransformFlags.IsEmpty);
Symbols\Metadata\PE\MemberRefMetadataDecoder.cs (2)
305if (targetCustomModifiers.IsDefault || targetCustomModifiers.IsEmpty) 307return candidateCustomModifiers.IsDefault || candidateCustomModifiers.IsEmpty;
Symbols\Metadata\PE\PEFieldSymbol.cs (1)
333if (customModifiersArray.IsEmpty && IsFixedBuffer(out fixedSize, out fixedElementType))
Symbols\Metadata\PE\PEMethodSymbol.cs (6)
712if (!memberNotNull.IsEmpty) 720if (!memberNotNullWhenTrue.IsEmpty) 726if (!memberNotNullWhenFalse.IsEmpty) 1053if (!attributeData.IsEmpty) 1282if (!SyntaxFacts.IsValidIdentifier(this.Name) && !this.ExplicitInterfaceImplementations.IsEmpty) 1529if (!result.IsEmpty)
Symbols\Metadata\PE\PEParameterSymbol.cs (2)
439Debug.Assert(_refCustomModifiers.IsEmpty || isByRef); 872if (paramNames.IsEmpty)
Symbols\Metadata\PE\PEPropertySymbol.cs (1)
743if (!attributes.IsEmpty)
Symbols\Metadata\PE\PETypeParameterSymbol.cs (2)
355if (constraintTypes.IsEmpty) 533else if (GetDeclaredConstraintTypes(ConsList<PETypeParameterSymbol>.Empty).IsEmpty)
Symbols\Metadata\PE\TupleTypeDecoder.cs (1)
308if (typeArgs.IsEmpty)
Symbols\NamedTypeSymbol.cs (4)
212if (candidates.IsEmpty) 273if (instanceCandidates.IsEmpty && staticCandidates.IsEmpty) 310if (candidates.IsEmpty)
Symbols\OverriddenOrHiddenMembersHelpers.cs (1)
506Debug.Assert(overriddenMembers.IsEmpty);
Symbols\OverriddenOrHiddenMembersResult.cs (2)
44if (overriddenMembers.IsEmpty && hiddenMembers.IsEmpty)
Symbols\ReducedExtensionMethodSymbol.cs (1)
87Debug.Assert(!method.TypeArgumentsWithAnnotations.IsEmpty);
Symbols\Retargeting\RetargetingEventSymbol.cs (1)
111if (impls.IsEmpty)
Symbols\Retargeting\RetargetingMethodSymbol.cs (1)
314if (impls.IsEmpty)
Symbols\Retargeting\RetargetingPropertySymbol.cs (1)
170if (impls.IsEmpty)
Symbols\Source\LocalFunctionSymbol.cs (1)
100=> _typeParameters.IsEmpty ? _binder : new WithMethodTypeParametersBinder(this, _binder);
Symbols\Source\SourceAssemblySymbol.cs (5)
145if (!compilation.Options.CryptoPublicKey.IsEmpty) 496Debug.Assert(!DeclaringCompilation.Options.Errors.IsEmpty); 619DeclaringCompilation.Options.CryptoPublicKey.IsEmpty && 2318if (identity.PublicKey.IsEmpty) 2922if (GetAttributeDeclarations().IsEmpty)
Symbols\Source\SourceComplexParameterSymbol.cs (2)
1732Debug.Assert(!refCustomModifiers.IsEmpty); 1737Debug.Assert(refKind != RefKind.None || _refCustomModifiers.IsEmpty);
Symbols\Source\SourceCustomEventSymbol.cs (1)
224if (!_explicitInterfaceImplementations.IsEmpty)
Symbols\Source\SourceEventSymbol.cs (1)
669if (!explicitInterfaceImplementations.IsEmpty)
Symbols\Source\SourceMemberContainerSymbol.cs (4)
1014if (IsImplicitlyDeclared && declarations.IsEmpty) 1173if (!group.IsEmpty && 2495else if (!ops1.IsEmpty) 2959if (initializers.IsEmpty)
Symbols\Source\SourceMethodSymbolWithAttributes.cs (1)
1498&& boundAttributes.IsEmpty
Symbols\Source\SourceModuleSymbol.cs (1)
721if (attributesDeclarations.IsEmpty)
Symbols\Source\SourceNamedTypeSymbol.cs (1)
370if (results.All(clause => clause.ConstraintTypes.IsEmpty))
Symbols\Source\SourceNamedTypeSymbol_Bases.cs (1)
664Debug.Assert(GetDeclaredInterfaces(basesBeingResolved: null).IsEmpty, "Computation skipped for enums");
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (11)
120Debug.Assert(GetAliasesAndUsingsForAsserts(declarationSyntax).GetExternAliases(this, declarationSyntax).IsEmpty); 130Debug.Assert(GetAliasesAndUsingsForAsserts(declarationSyntax).GetExternAliases(this, declarationSyntax).IsEmpty); 151Debug.Assert(GetAliasesAndUsingsForAsserts(declarationSyntax).GetUsingAliases(this, declarationSyntax, basesBeingResolved).IsEmpty); 161Debug.Assert(GetAliasesAndUsingsForAsserts(declarationSyntax).GetUsingAliases(this, declarationSyntax, basesBeingResolved).IsEmpty); 225Debug.Assert(GetAliasesAndUsingsForAsserts(declarationSyntax).GetUsingNamespacesOrTypes(this, declarationSyntax, basesBeingResolved).IsEmpty); 321if (!namespacesOrTypes.IsEmpty) 447Debug.Assert(result.IsEmpty); 580Debug.Assert(calculated.UsingAliases.IsEmpty); 582Debug.Assert(calculated.UsingNamespacesOrTypes.IsEmpty); 779diagnostics.Add(!globalUsingNamespacesOrTypes.IsEmpty && getOrCreateUniqueGlobalUsingsNotInTree(ref uniqueGlobalUsings, globalUsingNamespacesOrTypes, declarationSyntax.SyntaxTree).Contains(imported) ? 805diagnostics.Add(!globalUsingNamespacesOrTypes.IsEmpty && getOrCreateUniqueGlobalUsingsNotInTree(ref uniqueGlobalUsings, globalUsingNamespacesOrTypes, declarationSyntax.SyntaxTree).Contains(imported) ?
Symbols\Source\SourceOrdinaryMethodOrUserDefinedOperatorSymbol.cs (2)
84Debug.Assert(_lazyReturnType.CustomModifiers.IsEmpty); 146Debug.Assert(_lazyReturnType.CustomModifiers.IsEmpty);
Symbols\Source\SourceOrdinaryMethodSymbol.cs (2)
172Debug.Assert(declaredConstraints.All(clause => clause.ConstraintTypes.IsEmpty)); 990_typeParameterInfo = typeParameters.IsEmpty
Symbols\Source\SourceParameterSymbol.cs (1)
129if (newRefCustomModifiers.IsEmpty)
Symbols\Source\SourcePropertyAccessorSymbol.cs (3)
814if (!NotNullMembers.IsEmpty) 822if (!NotNullWhenTrueMembers.IsEmpty || !NotNullWhenFalseMembers.IsEmpty)
Symbols\Source\SourcePropertySymbolBase.cs (2)
268Debug.Assert(isExplicitInterfaceImplementation || _lazyExplicitInterfaceImplementations.IsEmpty); 617Debug.Assert(_lazyExplicitInterfaceImplementations.IsEmpty);
Symbols\Source\SourceTypeParameterSymbol.cs (7)
36Debug.Assert(!syntaxRefs.IsEmpty); 340this.ConstraintTypesNoUseSiteDiagnostics.IsEmpty && 419else if (!this.HasValueTypeConstraint && this.ConstraintTypesNoUseSiteDiagnostics.IsEmpty && this.IsNotNullable == false) 591if (constraintTypes.IsEmpty && GetConstraintKinds() == TypeParameterConstraintKind.None) 733var constraintTypes = constraints.IsEmpty ? ImmutableArray<TypeWithAnnotations>.Empty : constraints[Ordinal]; 735if (constraintTypes.IsEmpty && GetConstraintKinds() == TypeParameterConstraintKind.None) 746return constraintKinds.IsEmpty ? TypeParameterConstraintKind.None : constraintKinds[Ordinal];
Symbols\Source\TypeParameterConstraintClause.cs (1)
87if (constraintTypes.IsEmpty)
Symbols\SubstitutedParameterSymbol.cs (3)
57if (substituted.CustomModifiers.IsEmpty && 58this._underlyingParameter.TypeWithAnnotations.CustomModifiers.IsEmpty && 59this._underlyingParameter.RefCustomModifiers.IsEmpty)
Symbols\SubstitutedPropertySymbol.cs (1)
151if (unsubstitutedParameters.IsEmpty)
Symbols\SubstitutedTypeParameterSymbol.cs (1)
155if (_underlyingTypeParameter.ConstraintTypesNoUseSiteDiagnostics.IsEmpty)
Symbols\Symbol.cs (2)
425return locations.IsEmpty ? null : locations[0]; 497if (locations.IsEmpty)
Symbols\SymbolExtensions.cs (2)
35Debug.Assert(type.TypeParameters.IsEmpty == (typeArguments.Length == 0)); 36return type.TypeParameters.IsEmpty ? type : type.Construct(typeArguments, unbound: false);
Symbols\Synthesized\Records\SynthesizedRecordPrintMembers.cs (3)
134if (printableMembers.IsEmpty) 165if (printableMembers.IsEmpty) 180Debug.Assert(!printableMembers.IsEmpty);
Symbols\Synthesized\SynthesizedBackingFieldSymbol.cs (1)
158if (!allAttributeSyntaxNodes.IsEmpty && _property.IsAutoPropertyOrUsesFieldKeyword)
Symbols\Synthesized\SynthesizedParameterSymbol.cs (1)
359Debug.Assert(isParams || !refCustomModifiers.IsEmpty || baseParameterForAttributes is object || defaultValue is not null || hasUnscopedRefAttribute);
Symbols\Tuples\TupleErrorFieldSymbol.cs (1)
211_locations.IsEmpty ? null : GetFirstLocation(),
Symbols\TypeParameterSymbol.cs (1)
557if (constraintTypes.IsEmpty)
Symbols\TypeSymbol.cs (2)
109if (!interfaces.IsEmpty) 1151if (allInterfaces.IsEmpty)
Symbols\TypeSymbolExtensions.cs (2)
836if (fields.IsEmpty) 867if (typeArguments.IsEmpty)
Symbols\TypeWithAnnotations.cs (9)
196Debug.Assert(CustomModifiers.IsEmpty); 451Debug.Assert(newTypeWithModifiers.CustomModifiers.IsEmpty); 460newCustomModifiers.IsEmpty) 564CustomModifiers.IsEmpty; 844if (customModifiers.IsEmpty) 1069Debug.Assert(underlying.CustomModifiers.IsEmpty); 1103Debug.Assert(resolvedType.IsNullableType() && CustomModifiers.IsEmpty); 1114if (customModifiers.IsEmpty) 1163newUnderlying.CustomModifiers.IsEmpty)
Utilities\TypeSymbolExtensions.cs (2)
113if (!funcPtr.Signature.RefCustomModifiers.IsEmpty || checkTypeWithAnnotations(funcPtr.Signature.ReturnTypeWithAnnotations, flagNonDefaultArraySizesOrLowerBounds)) 120if (!param.RefCustomModifiers.IsEmpty || checkTypeWithAnnotations(param.TypeWithAnnotations, flagNonDefaultArraySizesOrLowerBounds))
Microsoft.CodeAnalysis.CSharp.CodeStyle (7)
src\Analyzers\CSharp\Analyzers\MakeAnonymousFunctionStatic\MakeAnonymousFunctionStaticDiagnosticAnalyzer.cs (1)
49if (context.SemanticModel.AnalyzeDataFlow(anonymousFunction) is { Succeeded: true, Captured.IsEmpty: true })
src\Analyzers\CSharp\Analyzers\MakeLocalFunctionStatic\MakeLocalFunctionStaticHelper.cs (2)
41&& dataFlow.CapturedInside.IsEmpty; 47!dataFlow.CapturedInside.IsEmpty)
src\Analyzers\CSharp\Analyzers\RemoveUnreachableCode\RemoveUnreachableCodeHelpers.cs (1)
101if (!lastSection.IsEmpty)
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\UseCollectionExpressionHelpers.cs (1)
331GetAccessibleInstanceConstructor(constructors, c => c.Parameters.IsEmpty) ??
src\Analyzers\CSharp\Analyzers\UsePrimaryConstructor\CSharpUsePrimaryConstructorDiagnosticAnalyzer.cs (1)
490if (namedType.GetMembers(leftIdentifier.Identifier.ValueText).IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Utilities\TypeStyle\CSharpTypeStyleHelper.cs (1)
137return !deconstructionInfoOpt.HasValue || !deconstructionInfoOpt.Value.Nested.IsEmpty || deconstructionInfoOpt.Value.Method != null;
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (12)
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordEngine.cs (2)
61if (positionalParameterInfos.IsEmpty) 511if (expressions.IsEmpty)
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordHelpers.cs (2)
81methodSymbol.Parameters.IsEmpty && 373Arguments: ImmutableArray<IArgumentOperation> { IsEmpty: true },
src\Analyzers\CSharp\CodeFixes\GenerateConstructor\CSharpGenerateConstructorService.cs (1)
132if (symbolInfo.CandidateReason == CandidateReason.OverloadResolutionFailure && !symbolInfo.CandidateSymbols.IsEmpty)
src\Analyzers\CSharp\CodeFixes\GenerateMethod\GenerateDeconstructMethodCodeFixProvider.cs (1)
95if (info.Method != null || !info.Nested.IsEmpty)
src\Analyzers\CSharp\CodeFixes\MisplacedUsingDirectives\MisplacedUsingDirectivesCodeFixProvider.cs (1)
425if (fileHeader.IsEmpty)
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpCollectionExpressionRewriter.cs (2)
88if (preMatches is [{ Node: ExpressionSyntax } preMatch] && postMatches.IsEmpty) 92else if (preMatches.IsEmpty && postMatches is [{ Node: ExpressionSyntax } postMatch])
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForFluentCodeFixProvider.cs (1)
146if (matches.IsEmpty)
src\Analyzers\CSharp\CodeFixes\UseLocalFunction\CSharpUseLocalFunctionCodeFixProvider.cs (1)
142if (capturedVariables.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ITypeSymbolExtensions.TypeSyntaxGeneratorVisitor.cs (1)
148symbol.Signature.UnmanagedCallingConventionTypes.IsEmpty
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (3)
CodeActions\InlineMethod\CSharpInlineMethodTests_CrossLanguage.cs (1)
26Assert.True(actions.IsEmpty);
Diagnostics\DiagnosticAnalyzerDriver\DiagnosticAnalyzerDriverTests.cs (2)
782if (!nugetAnalyzers.IsEmpty) 787if (!nugetSuppressors.IsEmpty)
Microsoft.CodeAnalysis.CSharp.EditorFeatures2.UnitTests (1)
EmbeddedLanguages\Json\CSharpJsonParserTests.cs (1)
194if (diagnostics.IsEmpty)
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (3)
CodeGen\CodeGenOperators.cs (1)
5423for (int count = start; count <= limit && diagnostics.IsEmpty; count += step)
CodeGen\CodeGenTupleTest.cs (2)
6374Assert.True(tupleWithoutNames.GetMembers("Item1").Single().Locations.IsEmpty); 14468Assert.True(v2Type.Interfaces.IsEmpty);
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (13)
Attributes\InternalsVisibleToAndStrongNameTests.cs (9)
145Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty); 175Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty); 304Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty); 351Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty); 373Assert.True(other.Assembly.Identity.PublicKey.IsEmpty); 387Assert.True(other.Assembly.Identity.PublicKey.IsEmpty); 406Assert.True(other.Assembly.Identity.PublicKey.IsEmpty); 454Assert.True(other.Assembly.Identity.PublicKey.IsEmpty); 465Assert.True(other.Assembly.Identity.PublicKey.IsEmpty);
Semantics\PrimaryConstructorTests.cs (4)
3250Assert.True(c.Constructors.All(ctor => ctor.GetAttributes().IsEmpty)); 3251Assert.True(c.Constructors.All(ctor => ctor.GetReturnTypeAttributes().IsEmpty)); 3380Assert.True(c.Constructors.All(ctor => ctor.GetAttributes().IsEmpty)); 3401Assert.True(c.Constructors.All(ctor => ctor.GetAttributes().IsEmpty));
Microsoft.CodeAnalysis.CSharp.Features (27)
AddImport\CSharpAddImportFeatureService.cs (1)
565if (aliases.IsEmpty)
ChangeSignature\CSharpChangeSignatureService.cs (2)
311if (updatedLeadingTrivia != default && !updatedLeadingTrivia.IsEmpty) 782if (permutedParamNodes.IsEmpty)
Completion\CompletionProviders\CrefCompletionProvider.cs (1)
365if (commitRules.IsEmpty)
Completion\CompletionProviders\DeclarationName\DeclarationNameRecommender.cs (1)
297if (overloads.IsEmpty)
EditAndContinue\CSharpEditAndContinueAnalyzer.cs (1)
2545IMethodSymbol { ExplicitInterfaceImplementations.IsEmpty: false }
ExtractMethod\CSharpMethodExtractor.CSharpCodeGenerator.cs (1)
297if (statements.IsEmpty)
Snippets\AbstractCSharpForLoopSnippetProvider.cs (1)
50var iteratorName = NameGenerator.GenerateUniqueName(s_iteratorBaseNames, n => semanticModel.LookupSymbols(syntaxContext.Position, name: n).IsEmpty);
Snippets\AbstractCSharpMainMethodSnippetProvider.cs (1)
38!semanticModel.LookupSymbols(context.Position, container: enclosingTypeSymbol, name: WellKnownMemberNames.EntryPointMethodName).IsEmpty)
Snippets\CSharpForEachLoopSnippetProvider.cs (1)
78"item", name => semanticModel.LookupSymbols(position, name: name).IsEmpty);
src\Analyzers\CSharp\Analyzers\MakeAnonymousFunctionStatic\MakeAnonymousFunctionStaticDiagnosticAnalyzer.cs (1)
49if (context.SemanticModel.AnalyzeDataFlow(anonymousFunction) is { Succeeded: true, Captured.IsEmpty: true })
src\Analyzers\CSharp\Analyzers\MakeLocalFunctionStatic\MakeLocalFunctionStaticHelper.cs (2)
41&& dataFlow.CapturedInside.IsEmpty; 47!dataFlow.CapturedInside.IsEmpty)
src\Analyzers\CSharp\Analyzers\RemoveUnreachableCode\RemoveUnreachableCodeHelpers.cs (1)
101if (!lastSection.IsEmpty)
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\UseCollectionExpressionHelpers.cs (1)
331GetAccessibleInstanceConstructor(constructors, c => c.Parameters.IsEmpty) ??
src\Analyzers\CSharp\Analyzers\UsePrimaryConstructor\CSharpUsePrimaryConstructorDiagnosticAnalyzer.cs (1)
490if (namedType.GetMembers(leftIdentifier.Identifier.ValueText).IsEmpty)
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordEngine.cs (2)
61if (positionalParameterInfos.IsEmpty) 511if (expressions.IsEmpty)
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordHelpers.cs (2)
81methodSymbol.Parameters.IsEmpty && 373Arguments: ImmutableArray<IArgumentOperation> { IsEmpty: true },
src\Analyzers\CSharp\CodeFixes\GenerateConstructor\CSharpGenerateConstructorService.cs (1)
132if (symbolInfo.CandidateReason == CandidateReason.OverloadResolutionFailure && !symbolInfo.CandidateSymbols.IsEmpty)
src\Analyzers\CSharp\CodeFixes\GenerateMethod\GenerateDeconstructMethodCodeFixProvider.cs (1)
95if (info.Method != null || !info.Nested.IsEmpty)
src\Analyzers\CSharp\CodeFixes\MisplacedUsingDirectives\MisplacedUsingDirectivesCodeFixProvider.cs (1)
425if (fileHeader.IsEmpty)
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpCollectionExpressionRewriter.cs (2)
88if (preMatches is [{ Node: ExpressionSyntax } preMatch] && postMatches.IsEmpty) 92else if (preMatches.IsEmpty && postMatches is [{ Node: ExpressionSyntax } postMatch])
src\Analyzers\CSharp\CodeFixes\UseCollectionExpression\CSharpUseCollectionExpressionForFluentCodeFixProvider.cs (1)
146if (matches.IsEmpty)
src\Analyzers\CSharp\CodeFixes\UseLocalFunction\CSharpUseLocalFunctionCodeFixProvider.cs (1)
142if (capturedVariables.IsEmpty)
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (2)
EditAndContinue\BreakpointSpansTests.cs (1)
85var expectedEnvelope = expectedSpans.IsEmpty ? default : TextSpan.FromBounds(expectedSpans[0].Start, expectedSpans[^1].End);
ExtractClass\ExtractClassTests.cs (1)
3127if (selectedMembers.IsEmpty)
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (10)
Semantics\BindingTests.cs (5)
3391Assert.True(model.LookupSymbols(node1.SpanStart, name: "MathMin").IsEmpty); 3394Assert.True(model.LookupSymbols(node1.SpanStart, name: "F2").IsEmpty); 3395Assert.True(model.LookupSymbols(node1.SpanStart, name: "MathMax2").IsEmpty); 3396Assert.True(model.LookupSymbols(node1.SpanStart, name: "MathMax3").IsEmpty); 3746Assert.True(symbolInfo1.CandidateSymbols.IsEmpty);
Semantics\FieldInitializerBindingTests.cs (1)
264Assert.True(!boundInitializers.IsEmpty, "Expected non-null non-empty bound initializers");
Semantics\LookupPositionTests.cs (1)
2274Assert.True(symbols.IsEmpty);
Semantics\OperatorTests.cs (1)
3274if (arguments == null || arguments.Value.IsEmpty)
SourceGeneration\GeneratorDriverTests.cs (2)
2563Assert.True(driver.GetRunResult().Diagnostics.IsEmpty); 2573Assert.True(driver.GetRunResult().Diagnostics.IsEmpty);
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (17)
Compilation\CompilationAPITests.cs (1)
368Assert.True(ref1.Properties.Aliases.IsEmpty);
Compilation\GetSemanticInfoTests.cs (3)
4297Assert.True(info.CandidateSymbols.IsEmpty); 4302Assert.True(info.MemberGroup.IsEmpty); 4303Assert.True(info.MethodGroup.IsEmpty);
Compilation\ReferenceManagerTests.cs (3)
906Assert.True(dr1.Properties.Aliases.IsEmpty); 907Assert.True(dr2.Properties.Aliases.IsEmpty); 908Assert.True(dr3.Properties.Aliases.IsEmpty);
Symbols\AnonymousTypesSymbolTests.cs (2)
1645Assert.False(sym.Symbol.Locations.IsEmpty, "Symbol Location"); 1654Assert.False(m.Locations.IsEmpty, String.Format("No Location: {0}", m));
Symbols\CustomModifiersTests.cs (7)
74Assert.True(nullable.GetTypeArgumentCustomModifiers(0).IsEmpty); 84Assert.True(nullable.GetTypeArgumentCustomModifiers(0).IsEmpty); 139Assert.True(type.GetTypeArgumentCustomModifiers(0).IsEmpty); 149Assert.True(dictionary.GetTypeArgumentCustomModifiers(0).IsEmpty); 150Assert.True(dictionary.GetTypeArgumentCustomModifiers(1).IsEmpty); 157Assert.True(dictionary.GetTypeArgumentCustomModifiers(0).IsEmpty); 158Assert.True(dictionary.GetTypeArgumentCustomModifiers(1).IsEmpty);
Symbols\Source\NullablePublicAPITests.cs (1)
2634Assert.True(info.CandidateSymbols.IsEmpty);
Microsoft.CodeAnalysis.CSharp.Test.Utilities (3)
CompilationTestUtils.cs (1)
458if (allAnnotations.IsEmpty)
CSharpTestBase.cs (1)
1960if (localInfos.IsEmpty)
MockCSharpCompiler.cs (1)
86if (!_additionalReferences.IsEmpty)
Microsoft.CodeAnalysis.CSharp.Workspaces (4)
Simplification\Simplifiers\ExpressionSimplifier.cs (2)
245if (speculativeSymbols.IsEmpty && speculativeNamespacesAndTypes.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Utilities\TypeStyle\CSharpTypeStyleHelper.cs (1)
137return !deconstructionInfoOpt.HasValue || !deconstructionInfoOpt.Value.Nested.IsEmpty || deconstructionInfoOpt.Value.Method != null;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ITypeSymbolExtensions.TypeSyntaxGeneratorVisitor.cs (1)
148symbol.Signature.UnmanagedCallingConventionTypes.IsEmpty
Microsoft.CodeAnalysis.Debugging.Package (1)
CustomDebugInfoReader.cs (1)
493if (importStrings.IsEmpty)
Microsoft.CodeAnalysis.EditorFeatures (7)
InlineRename\InlineRenameSession.OpenTextBufferManager.cs (3)
359var firstDocumentReplacements = documentReplacements.FirstOrDefault(d => !d.Item2.IsEmpty); 377if (document == firstDocumentReplacements.document || replacements.IsEmpty) 413if (document == firstDocumentReplacements.document || replacements.IsEmpty)
IntelliSense\AsyncCompletion\ItemManager.CompletionListUpdater.cs (1)
285if (!_snapshotData.Defaults.IsEmpty)
IntelliSense\AsyncCompletion\ItemManager.cs (1)
167|| !data.Defaults.IsEmpty;
Tagging\AbstractAsynchronousTaggerProvider.TagSource.cs (2)
327if (_dataSource.Options.IsEmpty && _dataSource.FeatureOptions.IsEmpty)
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (4)
CommentSelection\AbstractToggleCommentTestBase.cs (1)
74if (!expectedSpans.IsEmpty)
CompleteStatement\AbstractCompleteStatementTests.cs (2)
41Contract.ThrowIfTrue(positions.IsEmpty && spans.IsEmpty, "Expected at least one test position"); 42Contract.ThrowIfTrue(!positions.IsEmpty && !spans.IsEmpty, "Cannot test positions and spans at the same time");
MoveStaticMembers\TestMoveStaticMembersService.cs (1)
39if (!ExpectedPrecheckedMembers.IsEmpty)
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (1)
Utilities\StackFrameUtils.cs (1)
98if (triviaArray.IsEmpty)
Microsoft.CodeAnalysis.ExpressionEvaluator.ExpressionCompiler (4)
ExpressionCompiler.cs (2)
415Debug.Assert(missingAssemblyIdentities.IsEmpty); 428if (!missingAssemblyIdentities.IsEmpty)
FrameDecoder.cs (2)
103if (!typeParameters.IsEmpty) 114if (!typeArguments.IsEmpty)
Microsoft.CodeAnalysis.ExpressionEvaluator.FunctionResolver (1)
MetadataResolver.cs (1)
80if (memberTypeParameters.IsEmpty)
Microsoft.CodeAnalysis.ExternalAccess.FSharp (1)
Internal\NavigateTo\FSharpNavigateToSearchService.cs (1)
58Contract.ThrowIfTrue(projects.IsEmpty);
Microsoft.CodeAnalysis.Features (81)
AddConstructorParametersFromMembers\AddConstructorParametersFromMembersCodeRefactoringProvider.State.cs (2)
55parametersForSelectedMembers.IsEmpty) 63return !ConstructorCandidates.IsEmpty;
AddDebuggerDisplay\AbstractAddDebuggerDisplayCodeRefactoringProvider.cs (2)
100=> methodSymbol is { Name: nameof(ToString), Arity: 0, Parameters.IsEmpty: true }; 103=> methodSymbol is { Name: DebuggerDisplayMethodName, Arity: 0, Parameters.IsEmpty: true };
CodeFixes\Configuration\ConfigurationUpdater.cs (2)
137if (!codeStyleOptionValues.IsEmpty) 350if (!codeStyleOptions.IsEmpty)
CodeFixes\Configuration\ConfigureCodeStyle\ConfigureCodeStyleOptionCodeFixProvider.cs (1)
69if (codeStyleOptions.IsEmpty)
CodeRefactorings\AddMissingImports\AbstractAddMissingImportsFeatureService.cs (1)
95if (fixes.IsEmpty)
CodeRefactorings\CodeRefactoring.cs (1)
40if (CodeActions.IsEmpty)
CodeRefactorings\SyncNamespace\AbstractSyncNamespaceCodeRefactoringProvider.MoveFileCodeAction.cs (1)
82if (parts.IsEmpty)
Common\GlyphExtensions.cs (1)
34return !glyphs.IsEmpty
Completion\CompletionChange.cs (1)
58if (TextChanges.IsEmpty)
Completion\CompletionItem.cs (1)
67internal bool HasAdditionalFilterTexts => !AdditionalFilterTexts.IsEmpty;
Completion\Providers\AbstractSymbolCompletionProvider.cs (1)
303if (relatedDocumentIds.IsEmpty)
Completion\Providers\ImportCompletionProvider\AbstractTypeImportCompletionService.cs (1)
154=> aliases.IsEmpty || aliases.Any(static alias => alias == MetadataReferenceProperties.GlobalAlias);
Completion\Providers\ImportCompletionProvider\ExtensionMethodImportCompletionHelper.cs (1)
215if (methodSymbol.ReturnsVoid || methodSymbol.ReturnType == null || targetTypeSymbols.IsEmpty)
Completion\Providers\ImportCompletionProvider\ExtensionMethodImportCompletionHelper.SymbolComputer.cs (1)
400if (!method.IsExtensionMethod || method.Parameters.IsEmpty || !IsAccessible(method, internalsVisible))
ConvertForEachToFor\AbstractConvertForEachToForCodeRefactoringProvider.cs (2)
320if (countImpl.ExplicitInterfaceImplementations.IsEmpty && 321indexerImpl.ExplicitInterfaceImplementations.IsEmpty)
ConvertTupleToStruct\AbstractConvertTupleToStructCodeRefactoringProvider.cs (1)
413return typeParameters.IsEmpty
Diagnostics\DiagnosticsUpdatedArgs.cs (1)
35Debug.Assert(kind != DiagnosticsUpdatedKind.DiagnosticsRemoved || diagnostics.IsEmpty);
EditAndContinue\AbstractEditAndContinueAnalyzer.cs (3)
951Debug.Assert(newActiveStatementSpans.IsEmpty || oldActiveStatements.Length == newActiveStatementSpans.Length); 952Debug.Assert(oldActiveStatements.IsEmpty || oldActiveStatements.Length == newActiveStatements.Count); 2513Debug.Assert(inBreakState || newActiveStatementSpans.IsEmpty);
EditAndContinue\DebuggingSession.cs (1)
795if (newDocumentActiveStatementSpans.IsEmpty)
EditAndContinue\DocumentAnalysisResults.cs (1)
205hasBlockingRudeEdits: !rudeEdits.IsEmpty);
EditAndContinue\EditAndContinueService.cs (2)
146Contract.ThrowIfTrue(captureAllMatchingDocuments && !captureMatchingDocuments.IsEmpty); 150if (captureAllMatchingDocuments || !captureMatchingDocuments.IsEmpty)
EditAndContinue\EditSession.cs (5)
153Contract.ThrowIfTrue(documentAnalyses.IsEmpty); 263if (newDocumentIds.IsEmpty) 266return !oldSolution.GetDocumentIdsWithFilePath(sourceFilePath).IsEmpty; 963Debug.Assert(!createBaselineDiagnostics.IsEmpty); 1108if (!emitResult.Diagnostics.IsEmpty)
EditAndContinue\EditSessionTelemetry.cs (1)
106if (errorsIds.IsEmpty && _projectsWithValidDelta.Count < MaxReportedProjectIds)
EmbeddedLanguages\Json\JsonParser.cs (1)
165if (sequence.IsEmpty)
EmbeddedLanguages\RegularExpressions\LanguageServices\RegexDocumentHighlighter.cs (1)
53if (!referencesOnTheRight.IsEmpty)
ExternalAccess\VSTypeScript\VSTypeScriptNavigateToSearchService.cs (1)
60Contract.ThrowIfTrue(projects.IsEmpty);
FindUsages\AbstractFindUsagesService_FindImplementations.cs (1)
78if (implementations.IsEmpty)
FindUsages\DefinitionItem.cs (1)
137Contract.ThrowIfFalse(classifiedSpans.IsEmpty || sourceSpans.Length == classifiedSpans.Length);
FindUsages\DefinitionItemFactory.cs (4)
123if (!metadataLocations.IsEmpty) 129if (sourceLocations.IsEmpty && metadataLocations.IsEmpty) 191Contract.ThrowIfTrue(namespaceSymbol.ConstituentNamespaces.IsEmpty);
FullyQualify\AbstractFullyQualifyService.cs (2)
92if (matchingTypeSearchResults.IsEmpty && matchingNamespaceSearchResults.IsEmpty)
GenerateFromMembers\AbstractGenerateFromMembersCodeRefactoringProvider.cs (1)
81=> property.Parameters.IsEmpty;
InheritanceMargin\AbstractInheritanceMarginService_Helpers.cs (2)
83if (!allDeclarationNodes.IsEmpty) 144if (!symbolAndLineNumbers.IsEmpty)
InheritanceMargin\InheritanceMarginItem.cs (1)
71=> targetItems.IsEmpty ? null : new(lineNumber, topLevelDisplayText, displayTexts, glyph, Order(targetItems));
InitializeParameter\InitializeParameterHelpersCore.cs (1)
71baseName, n => containingType.GetMembers(n).IsEmpty);
LanguageServices\SymbolDisplayService\AbstractSymbolDisplayService.AbstractSymbolDescriptionBuilder.cs (1)
251if (!captures.IsEmpty)
MoveStaticMembers\AbstractMoveStaticMembersRefactoringProvider.cs (1)
31if (selectedMemberNodes.IsEmpty)
NavigateTo\AbstractNavigateToSearchService.CachedDocumentSearch.cs (1)
71Contract.ThrowIfTrue(projects.IsEmpty);
NavigateTo\AbstractNavigateToSearchService.GeneratedDocumentSearch.cs (1)
32Contract.ThrowIfTrue(projects.IsEmpty);
NavigateTo\AbstractNavigateToSearchService.NormalSearch.cs (1)
79Contract.ThrowIfTrue(projects.IsEmpty);
NavigationBar\NavigationBarItems\RoslynNavigationBarItem.SymbolItem.cs (1)
88Contract.ThrowIfTrue(inDocumentInfo.Value.spans.IsEmpty, "If location is in document, it must have non-empty spans");
PullMemberUp\AbstractPullMemberUpRefactoringProvider.cs (1)
43if (selectedMemberNodes.IsEmpty)
QuickInfo\QuickInfoUtilities.cs (1)
83!remarksDocumentation.IsEmpty)
SignatureHelp\AbstractSignatureHelpProvider.cs (1)
252if (relatedDocuments.IsEmpty)
Snippets\SnippetChange.cs (1)
37if (textChanges.IsEmpty)
src\Analyzers\Core\Analyzers\Helpers\DiagnosticHelper.cs (2)
116if (additionalUnnecessaryLocations.IsEmpty) 187if (additionalUnnecessaryLocations.IsEmpty)
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\AbstractRemoveUnnecessaryPragmaSuppressionsDiagnosticAnalyzer.cs (1)
524if (suppressionInfo == null || !suppressionInfo.ProgrammaticSuppressions.IsEmpty)
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\SuppressMessageAttributeState.cs (1)
127return !resolvedSymbols.IsEmpty;
src\Analyzers\Core\Analyzers\RemoveUnusedMembers\AbstractRemoveUnusedMembersDiagnosticAnalyzer.cs (4)
785if (!methodSymbol.ExplicitInterfaceImplementations.IsEmpty) 835return ((IPropertySymbol)memberSymbol).ExplicitInterfaceImplementations.IsEmpty; 838return ((IEventSymbol)memberSymbol).ExplicitInterfaceImplementations.IsEmpty; 855return methodSymbol.Parameters.IsEmpty &&
src\Analyzers\Core\Analyzers\RemoveUnusedParametersAndValues\AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.BlockAnalyzer.cs (1)
87if (HasSyntaxErrors() || context.OperationBlocks.IsEmpty)
src\Analyzers\Core\Analyzers\UseCollectionInitializer\AbstractUseCollectionInitializerAnalyzer.cs (1)
87return postMatches.IsEmpty ? default : new(preMatches, postMatches);
src\Analyzers\Core\CodeFixes\FileHeaders\AbstractFileHeaderCodeFixProvider.cs (1)
232if (diagnostics.IsEmpty)
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.State.cs (1)
174&& ContainingType.GetMembers(WellKnownMemberNames.TopLevelStatementsEntryPointMethodName).IsEmpty;
src\Analyzers\Core\CodeFixes\ImplementInterface\ImplementInterfaceGenerator_DisposePattern.cs (1)
266baseName, n => containingType.GetMembers(n).IsEmpty);
src\Analyzers\Core\CodeFixes\RemoveUnusedParametersAndValues\AbstractRemoveUnusedValuesCodeFixProvider.cs (1)
837if (originalDeclStatementsToMoveOrRemove.IsEmpty)
src\Dependencies\CodeAnalysis.Debugging\CustomDebugInfoReader.cs (1)
493if (importStrings.IsEmpty)
StackTraceExplorer\AbstractStackTraceSymbolResolver.cs (2)
27return typeArguments.IsEmpty; 30if (typeArguments.IsEmpty)
StackTraceExplorer\StackTraceExplorerService.cs (1)
33if (matches.IsEmpty)
SyncNamespaces\AbstractSyncNamespacesService.cs (1)
44if (diagnosticsByProject.Values.All(diagnostics => diagnostics.IsEmpty))
TaskList\AbstractTaskListService.cs (1)
55if (descriptors.IsEmpty)
UnusedReferences\UnusedReferencesRemover.cs (1)
98if (unusedReferences.IsEmpty)
Microsoft.CodeAnalysis.Features.Test.Utilities (1)
EditAndContinue\EditAndContinueTestVerifier.cs (1)
181Assert.True(expectedResult.SemanticEdits.IsEmpty);
Microsoft.CodeAnalysis.InteractiveHost (2)
Interactive\Core\InteractiveHost.Service.cs (2)
525var sdkDirectory = s_currentPlatformInfo.PlatformAssemblyPaths.IsEmpty ? RuntimeEnvironment.GetRuntimeDirectory() : null; 562initializationScriptPath = args.SourceFiles.IsEmpty ? null : args.SourceFiles[0].Path;
Microsoft.CodeAnalysis.LanguageServer (1)
HostWorkspace\ProjectDependencyHelper.cs (1)
125if (projectPaths.IsEmpty)
Microsoft.CodeAnalysis.LanguageServer.Protocol (15)
Features\CodeFixes\CodeFixService.cs (3)
204if (diagnostics.IsEmpty) 207if (!diagnostics.IsEmpty) 638if (!applicableDiagnostics.IsEmpty)
Features\Diagnostics\DocumentAnalysisExecutor.cs (1)
384if (diagnostics.IsEmpty)
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.ActiveFileState.cs (2)
35return _syntax.Items.IsEmpty && _semantic.Items.IsEmpty;
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.InProcOrRemoteHostAnalyzerRunner.cs (1)
77Contract.ThrowIfFalse(!compilationWithAnalyzers.Analyzers.IsEmpty);
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer_GetDiagnosticsForSpan.cs (1)
450!existingData.Items.IsEmpty)
Features\UnifiedSuggestions\UnifiedSuggestedActionsSource.cs (1)
648if (result.IsEmpty)
Handler\CodeActions\CodeActionHelpers.cs (1)
451if (currentActions.IsEmpty)
Handler\Completion\CompletionResultFactory.cs (1)
231if (item.Rules.CommitCharacterRules.IsEmpty)
Handler\Configuration\DidChangeConfigurationNotificationHandler.cs (1)
78if (configurationsFromClient.IsEmpty)
Handler\Diagnostics\AbstractPullDiagnosticHandler.cs (1)
289Contract.ThrowIfFalse(diagnostics.IsEmpty);
Handler\Formatting\FormatDocumentOnTypeHandler.cs (1)
70if (textChanges.IsEmpty)
Handler\References\FindUsagesLSPContext.cs (1)
258if (symbol == null || symbol.Locations.IsEmpty || symbol.Kind == SymbolKind.Namespace)
Microsoft.CodeAnalysis.Rebuild (1)
CompilationOptionsReader.cs (1)
334(metadataReferenceInfo.ExternAlias is null && metadataReference.Properties.Aliases.IsEmpty) ||
Microsoft.CodeAnalysis.Remote.ServiceHub (2)
Services\DiagnosticAnalyzer\DiagnosticComputer.cs (2)
331if (analyzers.IsEmpty) 535Contract.ThrowIfFalse(!analyzers.IsEmpty);
Microsoft.CodeAnalysis.Remote.Workspaces (2)
Serialization\MessagePackFormatters.cs (2)
41=> (additionalFormatters.IsEmpty && additionalResolvers.IsEmpty) ? DefaultResolver : CompositeResolver.Create(Formatters.AddRange(additionalFormatters), s_resolvers.AddRange(additionalResolvers));
Microsoft.CodeAnalysis.Scripting (1)
Hosting\Resolvers\RuntimeMetadataReferenceResolver.cs (1)
207if (paths.IsEmpty)
Microsoft.CodeAnalysis.Scripting.UnitTests (4)
RuntimeMetadataReferenceResolverTests.cs (4)
41Assert.True(actualReferences.IsEmpty); 47Assert.True(actualReferences.IsEmpty); 56Assert.True(actualReferences.IsEmpty); 62Assert.True(actualReferences.IsEmpty);
Microsoft.CodeAnalysis.Test.Utilities (21)
Compilation\ControlFlowGraphVerifier.cs (11)
185if (!predecessors.IsEmpty) 436if (blocks[i + 1].Predecessors.IsEmpty) 1379if (!region.Locals.IsEmpty) 1390if (!region.LocalFunctions.IsEmpty) 1401if (!region.CaptureIds.IsEmpty) 1469Assert.False(region.Locals.IsEmpty && region.LocalFunctions.IsEmpty && region.CaptureIds.IsEmpty); 1585if (!branch.FinallyRegions.IsEmpty) 1591if (!branch.LeavingRegions.IsEmpty) 1602if (!branch.EnteringRegions.IsEmpty)
Compilation\OperationTreeVerifier.cs (6)
400if (!children.IsEmpty || operation.Kind != OperationKind.None) 445var localStr = !operation.Locals.IsEmpty ? $", {operation.Locals.Length} locals" : string.Empty; 449if (operation.Operations.IsEmpty) 496if (!operation.IgnoredArguments.IsEmpty) 508if (!operation.IgnoredDimensions.IsEmpty) 894else if (argumentRefKinds.IsEmpty)
Diagnostics\CommonDiagnosticAnalyzers.cs (2)
1574context.OperationBlocks.IsEmpty) 1592context.OperationBlocks.IsEmpty)
Diagnostics\DiagnosticExtensions.cs (2)
126Assert.False(assemblyIds.IsEmpty); 137Assert.True(assemblyIds.IsEmpty);
Microsoft.CodeAnalysis.UnitTests (16)
Collections\ImmutableArrayExtensionsTests.cs (2)
57Assert.Throws<NullReferenceException>(() => nullOrEmpty.IsEmpty); 60Assert.True(nullOrEmpty.IsEmpty);
MetadataReferences\MetadataReferencePropertiesTests.cs (2)
21Assert.True(m.Aliases.IsEmpty); 31Assert.True(m.Aliases.IsEmpty);
MetadataReferences\MetadataReferenceTests.cs (12)
107Assert.True(r.Properties.Aliases.IsEmpty); 138Assert.True(r.Properties.Aliases.IsEmpty); 154Assert.True(r.Properties.Aliases.IsEmpty); 170Assert.True(r.Properties.Aliases.IsEmpty); 193Assert.True(r.Properties.Aliases.IsEmpty); 213Assert.True(r.Properties.Aliases.IsEmpty); 263Assert.True(r.Properties.Aliases.IsEmpty); 327Assert.True(r5.Properties.Aliases.IsEmpty); 343Assert.True(r.Properties.Aliases.IsEmpty); 355Assert.True(r2.Properties.Aliases.IsEmpty); 374Assert.True(r.Properties.Aliases.IsEmpty); 386Assert.True(r2.Properties.Aliases.IsEmpty);
Microsoft.CodeAnalysis.VisualBasic (178)
Analysis\FlowAnalysis\AbstractFlowPass.vb (2)
825If Not sideEffects.IsEmpty Then 1114If Not arguments.IsEmpty Then
Analysis\FlowAnalysis\ControlFlowPass.vb (1)
121If node.CatchBlocks.IsEmpty Then
Analysis\FlowAnalysis\DataFlowPass.vb (2)
1109Return If(locations.IsEmpty, Nothing, locations(0)) 2049If declarations.IsEmpty Then
Analysis\ForLoopVerification.vb (1)
101If boundForStatement.NextVariablesOpt.IsEmpty Then
Binding\Binder_Attributes.vb (2)
60Debug.Assert(Not binders.IsEmpty) 61Debug.Assert(Not attributesToBind.IsEmpty)
Binding\Binder_Expressions.vb (2)
1728If Not invocation.ArgumentsOpt.IsEmpty Then 2827If accessibleConstructors.IsEmpty Then
Binding\Binder_Initializers.vb (2)
60If Not Me.BoundInitializers.IsEmpty Then 269Debug.Assert(Not fieldSymbols.IsEmpty)
Binding\Binder_Invocation.vb (6)
785If Not boundArguments.IsEmpty Then 883If Not asyncLambdaSubToFunctionMismatch.IsEmpty Then 1623If boundArguments.IsEmpty AndAlso boundTypeExpression Is Nothing Then 1636If Not boundArguments.IsEmpty Then 2744Debug.Assert(Not candidate.OptionalArguments.IsEmpty, "Optional arguments expected") 2924If Not args.IsEmpty Then
Binding\Binder_Lambda.vb (1)
558If Not block.Locals.IsEmpty Then
Binding\Binder_Latebound.vb (2)
154If Not arguments.IsEmpty Then 167If Not arguments.IsEmpty Then
Binding\Binder_ObjectInitializer.vb (1)
311ElseIf Not boundArguments.IsEmpty Then
Binding\Binder_Query.vb (1)
4691If arguments.IsEmpty Then
Binding\Binder_Statements.vb (3)
379If locals.IsEmpty Then 399If locals.IsEmpty Then 4757If catchBlocks.IsEmpty AndAlso finallyBlockOpt Is Nothing Then
Binding\BlockBaseBinder.vb (4)
38If Me._lazyLocalsMap Is Nothing AndAlso Not Me.Locals.IsEmpty Then 46Debug.Assert(Not locals.IsEmpty) 66If Not locals.IsEmpty AndAlso (options And (LookupOptions.NamespacesOrTypesOnly Or LookupOptions.LabelsOnly Or LookupOptions.MustNotBeLocalOrParameter)) = 0 Then 92If Not locals.IsEmpty AndAlso (options And (LookupOptions.NamespacesOrTypesOnly Or LookupOptions.LabelsOnly)) = 0 Then
Binding\DeclarationInitializerBinder.vb (1)
42Debug.Assert(symbol.Kind <> SymbolKind.Parameter OrElse additionalSymbols.IsEmpty)
Binding\DocumentationCommentBinder.vb (1)
158If Not symbols.IsEmpty Then
Binding\DocumentationCommentTypeParamBinder.vb (2)
63If Not typeParameters.IsEmpty Then 84If Not TypeParameters.IsEmpty Then
Binding\DocumentationCommentTypeParamRefBinder.vb (1)
26If Not result.IsEmpty Then
Binding\ExecutableCodeBinder.vb (2)
88If Not labels.IsEmpty Then 155If Not Labels.IsEmpty AndAlso (options And LookupOptions.LabelsOnly) = LookupOptions.LabelsOnly Then
Binding\MemberSemanticModel.vb (5)
1432If Not binders.IsEmpty Then 1501If Not binders.IsEmpty Then 1542If Not binders.IsEmpty Then 1567If Not binders.IsEmpty Then 1590If Not binders.IsEmpty Then
Binding\SyntheticBoundTrees\SynthesizedPropertyAccessorBase.vb (1)
162If Not handledEvents.IsEmpty Then
BoundTree\BoundCall.vb (1)
95Debug.Assert(DefaultArguments.IsNull OrElse Not Arguments.IsEmpty)
BoundTree\BoundObjectCreationExpression.vb (1)
31Debug.Assert(DefaultArguments.IsNull OrElse Not Arguments.IsEmpty)
BoundTree\BoundPropertyAccess.vb (1)
71Debug.Assert(DefaultArguments.IsNull OrElse Not Arguments.IsEmpty)
CodeGen\EmitAddress.vb (1)
151Dim hasLocals As Boolean = Not sequence.Locals.IsEmpty
CodeGen\EmitExpression.vb (3)
513Dim hasLocals As Boolean = Not sequence.Locals.IsEmpty 1947If Not sequence.Locals.IsEmpty Then 2055If Not sequence.Locals.IsEmpty Then
CodeGen\EmitStatement.vb (7)
821Dim hasLocals As Boolean = Not sequence.Locals.IsEmpty 953Debug.Assert(Not caseBlocks.IsEmpty) 975Debug.Assert(Not caseBlocks.IsEmpty) 976Debug.Assert(Not caseBlockLabels.IsEmpty) 1185Debug.Assert(Not caseBlocks.IsEmpty) 1186Debug.Assert(Not caseBlockLabels.IsEmpty) 1222Dim hasLocals As Boolean = Not scope.Locals.IsEmpty
CodeGen\Optimizer\StackScheduler.Analyzer.vb (1)
330If Not locals.IsEmpty Then
Compilation\ClsComplianceChecker.vb (6)
364Debug.Assert(typeParameters.IsEmpty OrElse IsTrue(GetDeclaredOrInheritedCompliance(context)), "Only call on compliant symbols") 376Debug.Assert(parameters.IsEmpty OrElse 766_diagnostics.ReportUseSite(attributeClass, If(symbol.Locations.IsEmpty, NoLocation.Singleton, symbol.Locations(0))) 834Dim location = If(symbol.Locations.IsEmpty, NoLocation.Singleton, symbol.Locations(0)) 930If parameters.IsEmpty Then 952If parameters.IsEmpty Then
Compilation\DocumentationComments\DocumentationCommentWalker.vb (1)
164If result.IsEmpty Then
Compilation\MethodCompiler.vb (1)
466If Not initializerGroup.IsEmpty Then
Compilation\SymbolInfo.vb (1)
24If symbols.IsEmpty AndAlso Not (reason = CandidateReason.None OrElse reason = CandidateReason.LateBound) Then
Compilation\VisualBasicCompilation.vb (1)
2418Debug.Assert(additionalTypes.IsEmpty)
Declarations\SingleNamespaceDeclaration.vb (1)
84Debug.Assert(Not singleDeclarations.IsEmpty)
Declarations\SingleNamespaceOrTypeDeclaration.vb (1)
49Debug.Assert(Not singleDeclarations.IsEmpty)
Emit\NamedTypeSymbolAdapter.vb (2)
479If Not handledEvents.IsEmpty Then 935If interfaces.IsEmpty Then
Emit\SymbolAdapter.vb (1)
96If userDefined.IsEmpty AndAlso synthesized Is Nothing Then
Lowering\AsyncRewriter\AsyncRewriter.AsyncMethodToClassRewriter.Spilling.vb (2)
38If Not nodes.IsEmpty Then 240If Not sideEffects.IsEmpty Then
Lowering\AsyncRewriter\AsyncRewriter.CapturedSymbolOrExpression.vb (1)
169Debug.Assert(Not indices.IsEmpty)
Lowering\AsyncRewriter\AsyncRewriter.SpillBuilder.vb (2)
93If Not expression.SpillFields.IsEmpty Then 124If other.IsEmpty Then
Lowering\Diagnostics\DiagnosticsPass_ExpressionLambdas.vb (3)
76If Not node.Locals.IsEmpty AndAlso Me.IsInExpressionLambda Then 182If initializer IsNot Nothing AndAlso Not initializer.Initializers.IsEmpty Then 235If innerBlock.Locals.IsEmpty AndAlso innerBlock.Statements.Length = 1 Then
Lowering\ExpressionLambdaRewriter\ExpressionLambdaRewriter.vb (5)
147Debug.Assert(block.Locals.IsEmpty OrElse 168If innerBlock.Locals.IsEmpty AndAlso innerBlock.Statements.Length = 1 Then 679If locals.IsEmpty AndAlso sideEffects.IsEmpty AndAlso value IsNot Nothing Then 712If initializer IsNot Nothing AndAlso Not initializer.Initializers.IsEmpty Then
Lowering\Instrumentation\CodeCoverageInstrumenter.vb (1)
185If dynamicAnalysisSpans.IsEmpty Then
Lowering\LambdaRewriter\LambdaRewriter.Analysis.vb (1)
244If (locals.IsEmpty) Then
Lowering\LambdaRewriter\LambdaRewriter.vb (1)
506Debug.Assert(typeArguments.IsEmpty)
Lowering\LocalRewriter\LocalRewriter.vb (1)
766If Not temporaries.IsEmpty Then
Lowering\LocalRewriter\LocalRewriter_Block.vb (1)
23If Not node.Locals.IsEmpty Then
Lowering\LocalRewriter\LocalRewriter_Call.vb (2)
135If arguments.IsEmpty Then 163If arguments.IsEmpty Then
Lowering\LocalRewriter\LocalRewriter_LateInvocation.vb (1)
83If Not tempArray.IsEmpty Then
Lowering\LocalRewriter\LocalRewriter_UnstructuredExceptionHandling.vb (1)
54If(body.Locals.IsEmpty,
Lowering\StateMachineRewriter\StateMachineRewriter.StateMachineMethodToClassRewriter.vb (1)
248If locals.IsEmpty Then
Lowering\UseTwiceRewriter.vb (2)
368If node.Arguments.IsEmpty Then 429If node.ArgumentsOpt.IsEmpty Then
SymbolDisplay\SymbolDisplayVisitor.Members.vb (1)
572If Me.Format.CompilerInternalOptions.IncludesOption(SymbolDisplayCompilerInternalOptions.IncludeCustomModifiers) AndAlso Not customModifiers.IsEmpty Then
Symbols\ArrayTypeSymbol.vb (1)
659Debug.Assert(lowerBounds.IsDefaultOrEmpty OrElse (Not lowerBounds.IsEmpty AndAlso (lowerBounds.Length <> rank OrElse Not lowerBounds.All(Function(b) b = 0))))
Symbols\BaseTypeAnalysis.vb (1)
335If Not bases.IsEmpty Then
Symbols\EmbeddedSymbols\EmbeddedSymbolManager.SymbolsCollection.vb (3)
378Debug.Assert(method.ExplicitInterfaceImplementations.IsEmpty) 381Debug.Assert(method.GetReturnTypeAttributes().IsEmpty) 385Debug.Assert(parameter.GetAttributes().IsEmpty)
Symbols\ErrorTypeSymbol.vb (1)
381If CandidateSymbols.IsEmpty Then
Symbols\FieldOrPropertyInitializer.vb (1)
69Debug.Assert(Not fieldsOrProperties.IsEmpty)
Symbols\Metadata\PE\MemberRefMetadataDecoder.vb (2)
249If targetReturnTypeCustomModifiers.IsDefault OrElse targetReturnTypeCustomModifiers.IsEmpty Then 250Return candidateReturnTypeCustomModifiers.IsDefault OrElse candidateReturnTypeCustomModifiers.IsEmpty
Symbols\Metadata\PE\PEMethodSymbol.vb (2)
633If Not attributeData.IsEmpty Then 1290If Not conditionalSymbols.IsEmpty Then
Symbols\Metadata\PE\PEParameterSymbol.vb (4)
91If customModifiers.IsEmpty AndAlso refCustomModifiers.IsEmpty Then 229Debug.Assert(_refCustomModifiers.IsEmpty OrElse isByRef) 248Debug.Assert(_refCustomModifiers.IsEmpty OrElse isByRef)
Symbols\Metadata\PE\TupleTypeDecoder.vb (2)
202Return If(decodedType.TypeParameters.IsEmpty, 238If typeArgs.IsEmpty Then
Symbols\NamedTypeSymbol.vb (2)
412If instanceCandidates.IsEmpty AndAlso sharedCandidates.IsEmpty Then
Symbols\OverriddenMembersResult.vb (3)
79If overriddenMembers.IsEmpty AndAlso inexactOverriddenMembers.IsEmpty AndAlso inaccessibleMembers.IsEmpty Then
Symbols\Retargeting\RetargetingEventSymbol.vb (1)
114If impls.IsEmpty Then
Symbols\Retargeting\RetargetingMethodSymbol.vb (1)
467If impls.IsEmpty Then
Symbols\Retargeting\RetargetingPropertySymbol.vb (1)
283If impls.IsEmpty Then
Symbols\Source\OverrideHidingHelper.vb (1)
843If overriddenMembers.IsEmpty Then
Symbols\Source\SourceAssemblySymbol.vb (5)
105If Not compilation.Options.CryptoPublicKey.IsEmpty Then 996If identity.PublicKey.IsEmpty Then 1265DeclaringCompilation.Options.CryptoPublicKey.IsEmpty AndAlso 1712Debug.Assert(Not DeclaringCompilation.Options.Errors.IsEmpty) 1837If GetAttributeDeclarations().IsEmpty Then
Symbols\Source\SourceClonedParameterSymbol.vb (1)
185Debug.Assert(_refCustomModifiers.IsEmpty OrElse IsByRef)
Symbols\Source\SourceComplexParameterSymbol.vb (5)
406If customModifiers.IsEmpty AndAlso refCustomModifiers.IsEmpty Then 433Debug.Assert(Not customModifiers.IsEmpty OrElse Not refCustomModifiers.IsEmpty) 437Debug.Assert(_refCustomModifiers.IsEmpty OrElse IsByRef)
Symbols\Source\SourceEventSymbol.vb (3)
198If Not implementedEvents.IsEmpty Then 379Return Not ExplicitInterfaceImplementations.IsEmpty 390If implementedEvents.IsEmpty Then
Symbols\Source\SourceFile.vb (2)
368If Not dependencies.IsEmpty Then 381Debug.Assert(dependencies.IsEmpty)
Symbols\Source\SourceMemberContainerTypeSymbol.vb (3)
314If Not typeParams.IsEmpty Then 1614If children.IsEmpty Then 2227If typeToTest.Locations.IsEmpty Then
Symbols\Source\SourceMemberMethodSymbol.vb (3)
213If Not Me.ExplicitInterfaceImplementations.IsEmpty Then 420If implementedMethods.IsEmpty Then 782Debug.Assert(Not instanceCtors.IsEmpty, "bind non-type members should have ensured at least one ctor for us")
Symbols\Source\SourceMethodSymbol.vb (1)
2005If (reference.IsEmpty) Then
Symbols\Source\SourceModuleSymbol.vb (1)
1205If mergedAttributes.IsEmpty Then
Symbols\Source\SourceNamedTypeSymbol.vb (1)
1674If Not localInterfaces.IsEmpty Then
Symbols\Source\SourceNamedTypeSymbol_ComClass.vb (3)
86If _syntheticInterfaces.IsEmpty Then 96If _syntheticInterfaces.IsEmpty Then 1898If interfaces.IsEmpty Then
Symbols\Source\SourcePropertySymbol.vb (1)
894If implementedProperties.IsEmpty Then
Symbols\Source\SourceSimpleParameterSymbol.vb (5)
163If customModifiers.IsEmpty AndAlso refCustomModifiers.IsEmpty Then 187Debug.Assert(Not customModifiers.IsEmpty OrElse Not refCustomModifiers.IsEmpty) 191Debug.Assert(_refCustomModifiers.IsEmpty OrElse IsByRef)
Symbols\Source\SourceTypeParameterSymbol.vb (1)
232Debug.Assert(Not syntaxRefs.IsEmpty)
Symbols\SubstitutedMethodSymbol.vb (1)
704Debug.Assert(Not typeArguments.IsEmpty)
Symbols\Symbol.vb (2)
367If locations.IsEmpty Then 393If nodes.IsEmpty Then
Symbols\SymbolExtensions.vb (1)
225Not method.ExplicitInterfaceImplementations.IsEmpty Then
Symbols\SynthesizedSymbols\SynthesizedOverridingWitheventsProperty.vb (1)
187Debug.Assert(_baseProperty.Parameters.IsEmpty)
Symbols\SynthesizedSymbols\SynthesizedParameterSymbol.vb (6)
298If customModifiers.IsEmpty AndAlso refCustomModifiers.IsEmpty Then 319If valueParameterCustomModifiers.IsEmpty Then 396Debug.Assert(Not customModifiers.IsEmpty OrElse Not refCustomModifiers.IsEmpty) 400Debug.Assert(Me._refCustomModifiers.IsEmpty OrElse Me.IsByRef)
Symbols\TypeParameterSymbol.vb (1)
206If constraints.IsEmpty Then
Symbols\TypeSubstitution.vb (2)
588Debug.Assert(Not alphaRenamedTypeParameters.IsEmpty) 602Debug.Assert(Not typeParametersDefinitions.IsEmpty AndAlso
Symbols\TypeSymbol.vb (1)
217If declaredInterfaces.IsEmpty Then
Symbols\TypeWithModifiers.vb (2)
63Return TypeSymbol.Equals(Me.Type, other, TypeCompareKind.ConsiderEverything) AndAlso Me.CustomModifiers.IsEmpty 77Debug.Assert(Me.CustomModifiers.IsEmpty)
Symbols\UnboundGenericType.vb (1)
523If originalTypeMembers.IsEmpty Then
Microsoft.CodeAnalysis.VisualBasic.CodeStyle (1)
src\Analyzers\VisualBasic\Analyzers\RemoveUnusedMembers\VisualBasicRemoveUnusedMembersDiagnosticAnalyzer.vb (1)
25If Not method.HandledEvents.IsEmpty Then
Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes (1)
src\Analyzers\VisualBasic\CodeFixes\UseCollectionInitializer\VisualBasicUseCollectionInitializerCodeFixProvider.vb (1)
48Contract.ThrowIfFalse(preMatches.IsEmpty)
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (11)
Attributes\InternalsVisibleToAndStrongNameTests.vb (10)
104Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty) 134Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty) 210Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty) 270Assert.True(comp.Assembly.Identity.PublicKey.IsEmpty) 302Assert.True(other.Assembly.Identity.PublicKey.IsEmpty) 350Assert.True(other.Assembly.Identity.PublicKey.IsEmpty) 369Assert.True(other.Assembly.Identity.PublicKey.IsEmpty) 511Assert.True(other.Assembly.Identity.PublicKey.IsEmpty) 540Assert.True(other.Assembly.Identity.PublicKey.IsEmpty) 1963Assert.True(emitResult.Diagnostics.IsEmpty)
CodeGen\CodeGenTests.vb (1)
13774If Not diagnostics.IsEmpty Then
Microsoft.CodeAnalysis.VisualBasic.ExpressionCompiler (2)
CompilationContext.vb (2)
64compilation.SyntaxTrees.IsEmpty Then 578If Not importRecordGroups.IsEmpty Then
Microsoft.CodeAnalysis.VisualBasic.Features (7)
ChangeSignature\VisualBasicChangeSignatureService.vb (1)
623If permutedParamNodes.IsEmpty() Then
ConvertForEachToFor\VisualBasicConvertForEachToForCodeRefactoringProvider.vb (2)
174If foreachOperation.NextVariables.IsEmpty AndAlso foreachStatement.NextStatement Is Nothing Then 179If Not foreachOperation.NextVariables.IsEmpty Then
EditAndContinue\VisualBasicEditAndContinueAnalyzer.vb (2)
538If syntaxRefs.IsEmpty Then 2004If Not method.HandledEvents.IsEmpty Then
src\Analyzers\VisualBasic\Analyzers\RemoveUnusedMembers\VisualBasicRemoveUnusedMembersDiagnosticAnalyzer.vb (1)
25If Not method.HandledEvents.IsEmpty Then
src\Analyzers\VisualBasic\CodeFixes\UseCollectionInitializer\VisualBasicUseCollectionInitializerCodeFixProvider.vb (1)
48Contract.ThrowIfFalse(preMatches.IsEmpty)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (68)
Compilation\VisualBasicCompilationOptionsTests.vb (8)
147Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication).WithMainTypeName(Nothing).Errors.IsEmpty) 158Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication).WithRootNamespace(Nothing).Errors.IsEmpty) 164Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication).WithRootNamespace("").Errors.IsEmpty) 251Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication, mainTypeName:=Nothing).Errors.IsEmpty) 263Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication, rootNamespace:=Nothing).Errors.IsEmpty) 270Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication, rootNamespace:="").Errors.IsEmpty) 313Assert.True(options.Errors.IsEmpty) 320Assert.True(New VisualBasicCompilationOptions(OutputKind.ConsoleApplication).WithRootNamespace(rootNs).Errors.IsEmpty)
Semantics\ConditionalAccessTests.vb (9)
675Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1343Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1367Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1378Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1412Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1499Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1521Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1564Assert.True(symbolInfo.CandidateSymbols.IsEmpty) 1607Assert.True(symbolInfo.CandidateSymbols.IsEmpty)
Semantics\FieldInitializerBindingTests.vb (1)
1532Assert.[True](boundInitializers.IsEmpty)
Semantics\MultiDimensionalTest.vb (11)
876Assert.True(szArray.Sizes.IsEmpty) 883Assert.True(mdArray.Sizes.IsEmpty) 2140Assert.True(array.Sizes.IsEmpty) 2141Assert.True(array.LowerBounds.IsEmpty) 2147Assert.True(array.Sizes.IsEmpty) 2148Assert.True(array.LowerBounds.IsEmpty) 2154Assert.True(array.Sizes.IsEmpty) 2155Assert.True(array.LowerBounds.IsEmpty) 2231Assert.True(array.Sizes.IsEmpty) 2238Assert.True(array.Sizes.IsEmpty) 2245Assert.True(array.Sizes.IsEmpty)
Semantics\NameOfTests.vb (39)
70Assert.True(group.IsEmpty) 82Assert.True(group.IsEmpty) 107Assert.True(group.IsEmpty) 119Assert.True(group.IsEmpty) 135Assert.True(group.IsEmpty) 147Assert.True(group.IsEmpty) 467Assert.True(group.IsEmpty) 539Assert.True(group.IsEmpty) 878Assert.True(group.IsEmpty) 955Assert.True(group.IsEmpty) 1068Assert.True(group.IsEmpty) 1136Assert.True(group.IsEmpty) 1201Assert.True(group.IsEmpty) 1283Assert.True(group.IsEmpty) 1365Assert.True(group.IsEmpty) 1446Assert.True(group.IsEmpty) 1526Assert.True(group.IsEmpty) 1657Assert.True(group.IsEmpty) 1750Assert.True(group.IsEmpty) 1807Assert.True(group.IsEmpty) 1864Assert.True(group.IsEmpty) 1921Assert.True(group.IsEmpty) 2063Assert.True(group.IsEmpty) 2162Assert.True(group.IsEmpty) 2263Assert.True(group.IsEmpty) 2369Assert.True(group.IsEmpty) 2473Assert.True(group.IsEmpty) 2806Assert.True(group.IsEmpty) 2881Assert.True(group.IsEmpty) 2946Assert.True(group.IsEmpty) 3008Assert.True(group.IsEmpty) 3069Assert.True(group.IsEmpty) 3130Assert.True(group.IsEmpty) 3190Assert.True(group.IsEmpty) 3254Assert.True(group.IsEmpty) 3315Assert.True(group.IsEmpty) 3372Assert.True(group.IsEmpty) 3430Assert.True(group.IsEmpty) 3486Assert.True(group.IsEmpty)
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (7)
SymbolsTests\CustomModifiersTests.vb (7)
70Assert.True(nullable.GetTypeArgumentCustomModifiers(0).IsEmpty) 80Assert.True(nullable.GetTypeArgumentCustomModifiers(0).IsEmpty) 133Assert.True(type.GetTypeArgumentCustomModifiers(0).IsEmpty) 143Assert.True(dictionary.GetTypeArgumentCustomModifiers(0).IsEmpty) 144Assert.True(dictionary.GetTypeArgumentCustomModifiers(1).IsEmpty) 151Assert.True(dictionary.GetTypeArgumentCustomModifiers(0).IsEmpty) 152Assert.True(dictionary.GetTypeArgumentCustomModifiers(1).IsEmpty)
Microsoft.CodeAnalysis.VisualBasic.Test.Utilities (1)
MockVisualBasicCompiler.vb (1)
76If Not _additionalReferences.IsEmpty Then
Microsoft.CodeAnalysis.VisualBasic.Workspaces (1)
Simplification\Simplifiers\AbstractVisualBasicSimplifier.vb (1)
173Return boundSymbols.IsEmpty
Microsoft.CodeAnalysis.Workspaces (52)
CodeFixes\FixAllOccurrences\FixAllContextHelper.cs (1)
100if (allDiagnostics.IsEmpty)
CodeFixesAndRefactorings\FixAllProviderInfo.cs (3)
65if (scopes.IsEmpty) 85if (scopes.IsEmpty) 105if (scopes.IsEmpty)
CodeRefactorings\SyntaxEditorBasedCodeRefactoringProvider.cs (1)
26if (SupportedFixAllScopes.IsEmpty)
Diagnostics\DiagnosticAnalysisResult.cs (1)
92IsEmpty = DocumentIds.IsEmpty && _others.IsEmpty;
Diagnostics\Extensions.cs (3)
199if (!additionalPragmaSuppressionDiagnostics.IsEmpty && 258if (diagnostics.IsEmpty) 305if (diagnosticIdsToFilter.IsEmpty && includeSuppressedDiagnostics && !filterSpan.HasValue)
Diagnostics\SkippedHostAnalyzersInfo.cs (1)
112if (fullySkippedHostAnalyzers.IsEmpty && filteredDiagnosticIdsForAnalyzers.IsEmpty)
FindSymbols\FindReferences\Finders\AbstractReferenceFinder.cs (1)
187if (tokens.IsEmpty)
FindSymbols\FindReferences\Finders\PropertySymbolReferenceFinder.cs (1)
155useResult = accessors.IsEmpty;
Options\GlobalOptionService.cs (1)
269Debug.Assert(!changedOptions.IsEmpty);
Options\LegacyWorkspaceOptionService.cs (1)
81if (!internallyDefinedOptions.IsEmpty || anyExternallyDefinedOptionChanged)
Recommendations\AbstractRecommendationServiceRunner.cs (2)
116if (parameterTypeSymbols.IsEmpty) 430if (constraintTypes.IsEmpty)
src\Compilers\Core\Portable\Collections\ImmutableArrayExtensions.cs (4)
352if (array.IsEmpty) 370if (array.IsEmpty) 448if (self.IsEmpty) 1040if (items.IsEmpty)
src\Compilers\Core\Portable\Text\TextChangeRangeExtensions.cs (2)
120if (oldChanges.IsEmpty) 125if (newChanges.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EditorConfig\Parsing\Sections\SectionMatcher.cs (1)
302if (_numberRangePairs.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SemanticModelExtensions.cs (1)
162if (type.TypeKind == TypeKind.Array && typeArguments.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
170!branch.FinallyRegions.IsEmpty)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.FlowGraphAnalysisData.cs (1)
353if (!basicBlock.Predecessors.IsEmpty ||
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (3)
306=> SymbolSpecifications.IsEmpty && NamingStyles.IsEmpty && NamingRules.IsEmpty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\SymbolKey\SymbolKey.BodyLevelSymbolKey.cs (4)
23Contract.ThrowIfTrue(symbol.DeclaringSyntaxReferences.IsEmpty && symbol.Locations.IsEmpty); 62Contract.ThrowIfTrue(symbol.DeclaringSyntaxReferences.IsEmpty && symbol.Locations.IsEmpty);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\IDictionaryExtensions.cs (1)
140dictionary[key] = existingArray.IsEmpty && value.Equals(defaultArray[0]) ? defaultArray : existingArray.Add(value);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\TypeInferenceService\AbstractTypeInferenceService.cs (2)
20if (result.IsEmpty && nameOpt != null) 31if (result.IsEmpty && nameOpt != null)
Workspace\ProjectSystem\ProjectSystemProject.BatchingDocumentCollection.cs (1)
496if (filePaths.IsEmpty)
Workspace\ProjectSystem\ProjectSystemProject.cs (1)
1083if (!vsixRazorAnalyzers.IsEmpty)
Workspace\ProjectSystem\ProjectSystemProjectFactory.ProjectUpdateState.cs (1)
104if (projects.IsEmpty)
Workspace\ProjectSystem\ProjectSystemProjectOptionsProcessor.cs (1)
77if (!arguments.IsEmpty)
Workspace\Solution\ProjectState.cs (8)
758if (documents.IsEmpty) 770if (documents.IsEmpty) 782if (documents.IsEmpty) 813if (documentIds.IsEmpty) 826if (documentIds.IsEmpty) 836if (documentIds.IsEmpty) 862Contract.ThrowIfTrue(oldDocuments.IsEmpty); 888Contract.ThrowIfTrue(oldDocuments.IsEmpty);
Workspace\Solution\SolutionCompilationState.cs (4)
850if (newDocumentStates.IsEmpty) 1335if (documents.IsEmpty) 1648if (documentInfos.IsEmpty) 1667if (documentIds.IsEmpty)
Microsoft.CodeAnalysis.Workspaces.MSBuild (1)
MSBuild\MSBuildProjectLoader.Worker_ResolveReferences.cs (1)
271if (projectReferenceInfos.IsEmpty)
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (6)
MSBuild\ProjectFile\ProjectFile.cs (2)
400if (!aliases.IsEmpty) 478if (!reference.Aliases.IsEmpty)
src\Compilers\Core\Portable\Collections\ImmutableArrayExtensions.cs (4)
352if (array.IsEmpty) 370if (array.IsEmpty) 448if (self.IsEmpty) 1040if (items.IsEmpty)
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (3)
Options\OptionsTestHelpers.cs (3)
134ImmutableArray<bool> array => array.IsEmpty ? ImmutableArray.Create(true) : [], 136ImmutableArray<int> array => array.IsEmpty ? ImmutableArray.Create(1) : [], 137ImmutableArray<long> array => array.IsEmpty ? ImmutableArray.Create(1L) : [],
Microsoft.CodeAnalysis.Workspaces.UnitTests (21)
SolutionTests\DocumentInfoTests.cs (3)
78Assert.True(((ImmutableArray<string>)info2.Folders).IsEmpty); 81Assert.True(((ImmutableArray<string>)info3.Folders).IsEmpty); 84Assert.True(((ImmutableArray<string>)info4.Folders).IsEmpty);
SolutionTests\ProjectInfoTests.cs (15)
79Assert.True(((ImmutableArray<DocumentInfo>)info2.Documents).IsEmpty); 82Assert.True(((ImmutableArray<DocumentInfo>)info3.Documents).IsEmpty); 85Assert.True(((ImmutableArray<DocumentInfo>)info4.Documents).IsEmpty); 98Assert.True(((ImmutableArray<DocumentInfo>)info2.AdditionalDocuments).IsEmpty); 101Assert.True(((ImmutableArray<DocumentInfo>)info3.AdditionalDocuments).IsEmpty); 104Assert.True(((ImmutableArray<DocumentInfo>)info4.AdditionalDocuments).IsEmpty); 117Assert.True(((ImmutableArray<ProjectReference>)info2.ProjectReferences).IsEmpty); 120Assert.True(((ImmutableArray<ProjectReference>)info3.ProjectReferences).IsEmpty); 123Assert.True(((ImmutableArray<ProjectReference>)info4.ProjectReferences).IsEmpty); 136Assert.True(((ImmutableArray<MetadataReference>)info2.MetadataReferences).IsEmpty); 139Assert.True(((ImmutableArray<MetadataReference>)info3.MetadataReferences).IsEmpty); 142Assert.True(((ImmutableArray<MetadataReference>)info4.MetadataReferences).IsEmpty); 155Assert.True(((ImmutableArray<AnalyzerReference>)info2.AnalyzerReferences).IsEmpty); 158Assert.True(((ImmutableArray<AnalyzerReference>)info3.AnalyzerReferences).IsEmpty); 161Assert.True(((ImmutableArray<AnalyzerReference>)info4.AnalyzerReferences).IsEmpty);
SolutionTests\SolutionInfoTests.cs (3)
38Assert.True(((ImmutableArray<ProjectInfo>)info2.Projects).IsEmpty); 41Assert.True(((ImmutableArray<ProjectInfo>)info3.Projects).IsEmpty); 44Assert.True(((ImmutableArray<ProjectInfo>)info4.Projects).IsEmpty);
Microsoft.Extensions.Options.SourceGeneration (2)
ParserUtilities.cs (2)
83property.Kind == SymbolKind.Property && !property.IsStatic && property.GetMethod != null && property.Parameters.IsEmpty)) 97!property.IsStatic && property.GetMethod != null && property.Parameters.IsEmpty))
Microsoft.Gen.ComplianceReports.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
475if (diags.IsEmpty)
Microsoft.Gen.ContextualOptions (3)
Parser.cs (3)
65if (type.OptionsContextProperties.IsEmpty) 84.Where(prop => prop.Parameters.IsEmpty) 85.Where(prop => prop.ExplicitInterfaceImplementations.IsEmpty)
Microsoft.Gen.ContextualOptions.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
475if (diags.IsEmpty)
Microsoft.Gen.Logging.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
475if (diags.IsEmpty)
Microsoft.Gen.Metrics.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
475if (diags.IsEmpty)
Microsoft.Gen.MetricsReports.Unit.Tests (1)
test\Generators\Shared\RoslynTestUtils.cs (1)
475if (diags.IsEmpty)
Microsoft.Interop.ComInterfaceGenerator (8)
Analyzers\GeneratedComInterfaceAttributeAnalyzer.cs (1)
51if (comInterfaceAttribute.ConstructorArguments.IsEmpty)
ComInterfaceGenerator.cs (1)
417if (interfaces.IsEmpty)
UnmanagedToManagedStubGenerator.cs (4)
56Debug.Assert(statements.CleanupCalleeAllocated.IsEmpty); 59!statements.GuaranteedUnmarshal.IsEmpty 60|| !statements.CleanupCallerAllocated.IsEmpty 61|| !statements.ManagedExceptionCatchClauses.IsEmpty;
VirtualMethodPointerStubGenerator.cs (2)
110FunctionPointerCallingConvention(Token(SyntaxKind.UnmanagedKeyword), callConv.IsEmpty ? null : FunctionPointerUnmanagedCallingConventionList(SeparatedList(callConv))), 280FunctionPointerCallingConvention(Token(SyntaxKind.UnmanagedKeyword), callConv.IsEmpty ? null : FunctionPointerUnmanagedCallingConventionList(SeparatedList(callConv))),
Microsoft.Interop.JavaScript.JSImportGenerator (22)
JSExportCodeGenerator.cs (9)
71bool shouldInitializeVariables = !statements.GuaranteedUnmarshal.IsEmpty || !statements.CleanupCallerAllocated.IsEmpty || !statements.CleanupCalleeAllocated.IsEmpty; 77if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty)) 91if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty)) 116if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty))
JSExportGenerator.cs (3)
66if (data.Right.IsEmpty // no attributed methods 117if (generatedSources.IsEmpty) 225if (methods.IsEmpty) return NamespaceDeclaration(IdentifierName(generatedNamespace));
JSImportCodeGenerator.cs (9)
78bool shouldInitializeVariables = !statements.GuaranteedUnmarshal.IsEmpty || !statements.CleanupCallerAllocated.IsEmpty || !statements.CleanupCalleeAllocated.IsEmpty; 85if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty)) 99if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty)) 111if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty))
JSImportGenerator.cs (1)
64if (data.Right.IsEmpty // no attributed methods
Microsoft.Interop.LibraryImportGenerator (2)
LibraryImportGenerator.cs (2)
77if (data.Right.IsEmpty // no attributed methods 361if (!forwardedAttributes.IsEmpty)
Microsoft.Interop.LibraryImportGenerator.Downlevel (1)
DownlevelLibraryImportGenerator.cs (1)
265if (!forwardedAttributes.IsEmpty)
Microsoft.Interop.SourceGeneration (13)
IncrementalGeneratorInitializationContextExtensions.cs (3)
28.Select((topLevelAttrs, ct) => !topLevelAttrs.IsEmpty ? EnvironmentFlags.SkipLocalsInit : EnvironmentFlags.None); 40.Select((topLevelAttrs, ct) => !topLevelAttrs.IsEmpty ? EnvironmentFlags.DisableRuntimeMarshalling : EnvironmentFlags.None); 82if (generatedSources.IsEmpty)
ManagedToNativeStubGenerator.cs (9)
112bool shouldInitializeVariables = !statements.GuaranteedUnmarshal.IsEmpty || !statements.CleanupCallerAllocated.IsEmpty || !statements.CleanupCalleeAllocated.IsEmpty; 126if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty)) 155if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty)) 166if (!(statements.GuaranteedUnmarshal.IsEmpty && statements.CleanupCalleeAllocated.IsEmpty))
SyntaxExtensions.cs (1)
52if (!fixedStatements.IsEmpty)
Microsoft.ML.InternalCodeAnalyzer (1)
InstanceInitializerAnalyzer.cs (1)
69if (syntaxRefs.IsEmpty)
Microsoft.VisualStudio.LanguageServices (10)
Diagnostics\VisualStudioDiagnosticAnalyzerService.cs (1)
318if (!otherProjectsForMultiTfmProject.IsEmpty)
InheritanceMargin\InheritanceGlyphFactory.cs (1)
82Contract.ThrowIfTrue(membersOnLine.IsEmpty);
InheritanceMargin\InheritanceMarginTag.cs (1)
39Contract.ThrowIfTrue(membersOnLine.IsEmpty);
Library\ObjectBrowser\ObjectList.cs (1)
443if (typeSymbol.TypeKind == TypeKind.Interface && typeSymbol.Interfaces.IsEmpty)
Progression\GraphQueries\InheritsGraphQuery.cs (1)
41else if (namedType.TypeKind == TypeKind.Interface && !namedType.OriginalDefinition.AllInterfaces.IsEmpty)
StackTraceExplorer\StackFrameViewModel.cs (1)
164Debug.Assert(GetTrailingTrivia(className).IsEmpty);
SyncNamespaces\SyncNamespacesCommandHandler.cs (1)
128if (projects.IsEmpty)
UnusedReferences\RemoveUnusedReferencesCommandHandler.cs (1)
127referenceUpdates.IsEmpty)
ValueTracking\ValueTrackedTreeItemViewModel.cs (1)
78if (children.IsEmpty)
Workspace\VisualStudioDocumentNavigationService.cs (1)
221if (!documentIdsForFilePath.IsEmpty)
SemanticSearch.BuildTask (1)
GenerateFilteredReferenceAssembliesTask.cs (1)
275if (patterns.IsEmpty)
System.Collections.Immutable (14)
System\Collections\Immutable\ImmutableArray_1.Builder.cs (1)
305if (items.IsEmpty)
System\Collections\Immutable\ImmutableArray_1.cs (13)
206if (self.IsEmpty) 223if (self.IsEmpty && startIndex == 0) 319if (self.IsEmpty) 352if (self.IsEmpty) 405if (self.IsEmpty) 409if (items.IsEmpty) 425if (self.IsEmpty) 461else if (self.IsEmpty) 754if (self.IsEmpty) 938if (self.IsEmpty) 962if (self.IsEmpty) 985if (items.IsEmpty || self.IsEmpty) 1511Debug.Assert(!IsEmpty);
System.Text.Json.SourceGeneration (3)
src\libraries\Common\src\Roslyn\GlobalAliases.cs (1)
30return aliasAndSymbolNames.IsEmpty ? Empty : new GlobalAliases(aliasAndSymbolNames);
src\libraries\Common\src\Roslyn\SyntaxValueProvider_ForAttributeWithMetadataName.cs (1)
127if (!syntaxNodes.IsEmpty)
src\libraries\Common\src\SourceGenerators\TypeModelHelper.cs (1)
31if (!current.TypeArguments.IsEmpty)