120 references to Any
Microsoft.CodeAnalysis (4)
Syntax\SyntaxList`1.cs (4)
335if (this.Any()) 358if (this.Any()) 410if (this.Any()) 420if (this.Any())
Microsoft.CodeAnalysis.CodeStyle (2)
AbstractHeaderFacts.cs (1)
92if (attributeList.Any())
ISyntaxFactsExtensions.cs (1)
455if (attributeList.Any())
Microsoft.CodeAnalysis.CodeStyle.Fixes (3)
AbstractAddImportsService.cs (3)
55private bool HasExterns(SyntaxNode node) => GetExterns(node).Any(); 56private bool HasAnyImports(SyntaxNode node) => GetUsingsAndAliases(node).Any() || GetExterns(node).Any();
Microsoft.CodeAnalysis.CSharp (27)
Binder\LocalBinderFactory.cs (1)
769if (node.Catches.Any())
BoundTree\UnboundLambda.cs (2)
645if (_unboundLambda.ParameterAttributes(i).Any()) 708if (DeclaredScope(i) == ScopedKind.None && parameterScopesBuilder[i] == ScopedKind.ScopedRef && _unboundLambda.ParameterAttributes(i).Any())
CSharpDeclarationComputer.cs (1)
319if (t.AttributeLists.Any())
Declarations\DeclarationTreeBuilder.cs (8)
382hasExternAliases: compilationUnit.Externs.Any(), 386hasAssemblyAttributes: compilationUnit.AttributeLists.Any(), 419bool hasUsings = node.Usings.Any(); 420bool hasExterns = node.Externs.Any(); 601var declFlags = node.AttributeLists.Any() 708var declFlags = node.AttributeLists.Any() 741SingleTypeDeclaration.TypeDeclarationFlags declFlags = node.AttributeLists.Any() ? 814if (!anyMemberHasAttributes && member.AttributeLists.Any())
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (14)
25if (!compilationUnit.Externs.Any() && !compilationUnit.Usings.Any()) 47if (!namespaceDecl.Externs.Any() && !namespaceDecl.Usings.Any()) 106if (!compilationUnit.Externs.Any()) 116if (!namespaceDecl.Externs.Any()) 137if (!compilationUnit.Usings.Any()) 147if (!namespaceDecl.Usings.Any()) 168if (!compilationUnit.Usings.Any()) 179if (!namespaceDecl.Usings.Any()) 200if (!compilationUnit.Usings.Any()) 211if (!namespaceDecl.Usings.Any()) 431if (!externAliasDirectives.Any()) 563if (!usingDirectives.Any())
Symbols\Symbol_Attributes.cs (1)
587if (attributeDeclarationSyntaxList.Any())
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (4)
CompilationUnitSyntaxExtensions.cs (2)
60if (rootUsings.Any()) 69var end = root.Members.Any()
MisplacedUsingDirectivesCodeFixProvider.cs (1)
391var forcePreservation = compilationUnit.AttributeLists.Any()
UseSimpleUsingStatementCodeFixProvider.cs (1)
116if (!statements.Any())
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (2)
SymbolKey\SymbolKeyTestBase.cs (2)
140if (body != null && body.Statements.Any()) 310if (body != null && body.Statements.Any())
Microsoft.CodeAnalysis.CSharp.Features (8)
CodeFixes\Suppression\CSharpSuppressionCodeFixProvider.cs (2)
108var isFirst = !compilationRoot.AttributeLists.Any(); 133if (!memberNode.GetAttributes().Any())
Completion\CompletionProviders\OverrideCompletionProvider.cs (1)
226if (propertyDeclaration.AccessorList != null && propertyDeclaration.AccessorList.Accessors.Any())
CSharpDeclarationComputer.cs (1)
319if (t.AttributeLists.Any())
InvertIf\CSharpInvertIfCodeRefactoringProvider.cs (1)
195if (falseBlock.Statements.Any())
LineSeparators\CSharpLineSeparatorService.cs (1)
249if (usings.Any())
MisplacedUsingDirectivesCodeFixProvider.cs (1)
391var forcePreservation = compilationUnit.AttributeLists.Any()
UseSimpleUsingStatementCodeFixProvider.cs (1)
116if (!statements.Any())
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (1)
Compilation\UsedAssembliesTests.cs (1)
138if (!unit.Usings.Any())
Microsoft.CodeAnalysis.CSharp.Workspaces (15)
FindSymbols\CSharpDeclaredSymbolInfoFactoryService.cs (13)
193hasAttributes: localFunction.AttributeLists.Any(), 216typeDeclaration.Members.Any() && 229typeDeclaration.AttributeLists.Any(), 259enumDeclaration.AttributeLists.Any(), 287ctorDecl.AttributeLists.Any(), 303delegateDecl.AttributeLists.Any(), 317enumMember.AttributeLists.Any(), 331eventDecl.AttributeLists.Any(), 345indexerDecl.AttributeLists.Any(), 360method.AttributeLists.Any(), 376property.AttributeLists.Any(), 399fieldDeclaration.AttributeLists.Any(), 449parameter.AttributeLists.Any(),
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\CompilationUnitSyntaxExtensions.cs\CompilationUnitSyntaxExtensions.cs (2)
60if (rootUsings.Any()) 69var end = root.Members.Any()
Microsoft.CodeAnalysis.Features (1)
IntroduceUsingStatement\AbstractIntroduceUsingStatementCodeRefactoringProvider.cs (1)
163if (statementsToSurround.Any())
Microsoft.CodeAnalysis.VisualBasic (25)
Declarations\DeclarationTreeBuilder.vb (16)
214hasAssemblyAttributes:=node.Attributes.Any) 229hasAssemblyAttributes:=node.Attributes.Any) 496Dim declFlags As SingleTypeDeclaration.TypeDeclarationFlags = If(declarationSyntax.AttributeLists.Any(), 500If (typeBlockSyntax.Inherits.Any) Then 547Dim declFlags As SingleTypeDeclaration.TypeDeclarationFlags = If(declarationSyntax.AttributeLists.Any(), 626If field.AttributeLists.Any Then 639If methodDecl.AttributeLists.Any Then 647If propertyDecl.PropertyStatement.AttributeLists.Any Then 651If a.BlockStatement.AttributeLists.Any Then 665If methodDecl.AttributeLists.Any Then 673If eventDecl.EventStatement.AttributeLists.Any Then 677If a.BlockStatement.AttributeLists.Any Then 688If eventDecl.AttributeLists.Any Then 723If Not anyMemberHasAttributes AndAlso enumMember.AttributeLists.Any Then 742Dim declFlags As SingleTypeDeclaration.TypeDeclarationFlags = If(node.AttributeLists.Any(), 768Dim declFlags As SingleTypeDeclaration.TypeDeclarationFlags = If(node.AttributeLists.Any(),
Symbols\Source\SourceAssemblySymbol.vb (1)
481If attributeStatements.Any Then
Symbols\Source\SourceMethodSymbol.vb (1)
793Return blockSyntax Is Nothing OrElse Not blockSyntax.Statements.Any
Symbols\Source\SourceNamedTypeSymbol_GroupClass.vb (1)
133If list.Any() Then
Symbols\Symbol_Attributes.vb (1)
313If attributeDeclarationSyntaxList.Any() Then
Syntax\SyntaxNormalizer.vb (5)
713If list.Any Then 732Dim hasImports = node.Imports.Any 733Dim hasMembers = node.Members.Any 734Dim hasAttributes = node.Attributes.Any 865If node.Statements.Any() Then
Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes (1)
SyntaxTreeExtensions.vb (1)
994If aggregateClause.AdditionalQueryOperators.Any() Then
Microsoft.CodeAnalysis.VisualBasic.EditorFeatures (3)
EndConstructGeneration\EndConstructStatementVisitor_IfStatement.vb (1)
48Dim position = If(ifBlock.Statements.Any(), ifBlock.Statements(0).SpanStart, ifBlock.IfStatement.Span.End + _state.NewLineCharacter.Length)
LineCommit\ContainingStatementInfo.vb (1)
172If Not attributes.Any Then
Utilities\LineAdjustmentFormattingRule.vb (1)
33Not DirectCast(current.Parent.Parent, MethodBlockSyntax).Statements.Any() Then
Microsoft.CodeAnalysis.VisualBasic.Features (7)
CodeFixes\MoveToTopOfFile\MoveToTopOfFileCodeFixProvider.vb (5)
102If root.Imports.Any() Then 104ElseIf root.Options.Any() Then 140If root.Attributes.Any() Then 142ElseIf root.Imports.Any() Then 144ElseIf root.Options.Any() Then
CodeFixes\Suppression\VisualBasicSuppressionCodeFixProvider.vb (1)
126Dim isFirst = Not compilationRoot.Attributes.Any()
LineSeparators\VisualBasicLineSeparatorService.vb (1)
146If importsList.Any() Then
Microsoft.CodeAnalysis.VisualBasic.Workspaces (12)
FindSymbols\VisualBasicDeclaredSymbolInfoFactoryService.vb (10)
152typeDeclaration.Members.Any() AndAlso 165blockStatement.AttributeLists.Any(), 191enumStatement.AttributeLists.Any(), 228constructor.AttributeLists.Any(), 246delegateDecl.AttributeLists.Any(), 260enumMember.AttributeLists.Any(), 274eventDecl.AttributeLists.Any(), 290funcDecl.AttributeLists.Any(), 308propertyDecl.AttributeLists.Any(), 324fieldDecl.AttributeLists.Any(),
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\VisualBasic\Extensions\ContextQuery\SyntaxTreeExtensions.vb\SyntaxTreeExtensions.vb (1)
994If aggregateClause.AdditionalQueryOperators.Any() Then
Simplification\VisualBasicSimplificationService.vb (1)
96Contract.ThrowIfFalse(originalMethod.Statements.Any(), "How did empty method body get reduced?")
Microsoft.CodeAnalysis.Workspaces (5)
AbstractAddImportsService.cs (3)
55private bool HasExterns(SyntaxNode node) => GetExterns(node).Any(); 56private bool HasAnyImports(SyntaxNode node) => GetUsingsAndAliases(node).Any() || GetExterns(node).Any();
AbstractHeaderFacts.cs (1)
92if (attributeList.Any())
ISyntaxFactsExtensions.cs (1)
455if (attributeList.Any())