942 references to Any
AnalyzerRunner (1)
DiagnosticAnalyzerRunner.cs (1)
251if (options.RefactoringNodes.Any())
ApiExplorerWebSite (1)
ApiExplorerRouteChangeConvention.cs (1)
19if (action.Attributes.OfType<ReloadAttribute>().Any() && ChangeToken.TokenSource.IsCancellationRequested)
Aspire.Dashboard (3)
Authentication\AspirePolicyEvaluator.cs (1)
145newPrincipal.AddIdentities(existingPrincipal.Identities.Where(i => i.IsAuthenticated || i.Claims.Any()));
Components\Controls\Chart\ChartContainer.razor.cs (1)
131if (!filter.SelectedValues.Any())
Extensions\CollectionExtensions.cs (1)
15return !array.Where((t, i) => !Equals(t, other[i])).Any();
Aspire.EndToEnd.Tests (2)
tests\Shared\WorkloadTesting\TemplateCustomHive.cs (2)
55installTemplates = packageIdAndPaths.Where(t => new FileInfo(t.path).LastWriteTimeUtc > dirWriteTime).Any(); 89if (!packages.Any())
Aspire.Hosting (3)
ContainerResourceExtensions.cs (1)
40return resource.Annotations.OfType<ContainerImageAnnotation>().Any();
Dcp\ApplicationExecutor.cs (1)
1564if (containerResources.Any())
ProjectResourceBuilderExtensions.cs (1)
316if (projectResource.GetEndpoints().Any() && !projectResource.Annotations.OfType<DisableForwardedHeadersAnnotation>().Any())
Aspire.Hosting.Azure.AppContainers (1)
AzureContainerAppsInfrastructure.cs (1)
255if (!resource.TryGetEndpoints(out var endpoints) || !endpoints.Any())
Aspire.Hosting.Dapr (2)
DaprDistributedApplicationLifecycleHook.cs (1)
370if (onDemandComponents.Any())
src\Shared\Utf8JsonWriterExtensions.cs (1)
26if (valuesList.Any())
Aspire.Hosting.MySql (2)
MySqlBuilderExtensions.cs (2)
98if (builder.ApplicationBuilder.Resources.OfType<PhpMyAdminContainerResource>().Any()) 119if (!mySqlInstances.Any())
Aspire.Hosting.Redis (3)
RedisBuilderExtensions.cs (3)
102if (!redisInstances.Any()) 176if (!redisInstances.Any()) 271if (databasesToDelete.Any())
Aspire.Playground.Tests (1)
AppHostTests.cs (1)
298if (!theoryData.Any() && !string.IsNullOrEmpty(s_appHostNameFilter))
Aspire.Workload.Tests (2)
tests\Shared\WorkloadTesting\TemplateCustomHive.cs (2)
55installTemplates = packageIdAndPaths.Where(t => new FileInfo(t.path).LastWriteTimeUtc > dirWriteTime).Any(); 89if (!packages.Any())
BoundTreeGenerator (10)
BoundNodeClassWriter.cs (10)
664if (nullCheckFields.Any()) 815if (fieldsWithName.Any()) 902bool hasChildNodes = AllNodeOrNodeListFields(node).Any(); 929if (!AllFields(node).Any()) 932bool emitNew = (!Fields(node).Any()) && BaseType(node) is Node; 957if (AllSpecifiableFields(node).Any()) 1007if (AllSpecifiableFields(node).Any()) 1180if (!fields.Any()) 1366if (!AllNodeOrNodeListFields(node).Any() && !AllTypeFields(node).Any())
BuildBoss (1)
TargetsCheckerUtil.cs (1)
72if (util.GetTargets().Any())
ClientSample (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
CodeGenerator (3)
FeatureCollectionGenerator.cs (1)
216return values.Any() ? values.Select(formatter).Aggregate((a, b) => a + b) : "";
src\Servers\Kestrel\shared\KnownHeaders.cs (2)
310return values.Any() ? values.Select(formatter).Aggregate((a, b) => a + b) : ""; 315return values.Any() ? values.Select(formatter).Aggregate((a, b) => a + b) : "";
ConfigurationSchemaGenerator (1)
ConfigSchemaEmitter.cs (1)
556if (element.HasAttributes && !element.Nodes().Any())
CSharpSyntaxGenerator (4)
SourceWriter.cs (2)
942if (!relevantNodes.Any()) 988if (!relevantNodes.Any())
TestWriter.cs (2)
188if (!subTypes.Any()) 391return fieldKinds?.Any() == true ? fieldKinds[0].Name : "IdentifierToken";
CustomAuthorizationFailureResponse (1)
Authorization\SampleAuthorizationMiddlewareResultHandler.cs (1)
34if (policyAuthorizationResult.AuthorizationFailure.FailureReasons.Any())
dotnet-dev-certs (8)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
dotnet-getdocument (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
dotnet-openapi (7)
Commands\BaseCommand.cs (2)
158if (fileItems.Any()) 383if (uri.Segments.Any() && uri.Segments.Last() != "/")
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
dotnet-razorpagegenerator (2)
Program.cs (2)
102if (!cshtmlFiles.Any()) 128if (cSharpDocument.Diagnostics.Any())
dotnet-sql-cache (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
dotnet-svcutil-lib.Tests (3)
TestInit.cs (3)
180if (!Directory.Exists(pkgPath) || !Directory.GetFiles(pkgPath, "dotnet-svcutil-lib*.nupkg").Any()) 184Assert.True(Directory.GetFiles(pkgPath, "dotnet-svcutil-lib.*.nupkg").Any(), $"dotnet-svcutil-lib*.nupkg not found under {pkgPath}!"); 556if (!Directory.Exists(binDir) || !Directory.GetFiles(binDir, "dotnet-svcutil-lib.*.nupkg").Any())
dotnet-user-jwts (7)
Helpers\ConsoleTable.cs (1)
32if (!_columns.Any())
Helpers\DevJwtCliHelpers.cs (1)
214return enumerable == null || !enumerable.Any();
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
dotnet-user-secrets (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
GetDocument.Insider (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
IIS.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
illink (3)
installer.tasks (1)
GenerateFileVersionProps.cs (1)
113if (versionlessFiles.Any())
Interop.FunctionalTests (1)
H2SpecTests.cs (1)
69if (testCases == null || !testCases.Any())
InteropWebsite (2)
TestServiceImpl.cs (2)
109if (echoInitialList.Any()) 116if (echoTrailingList.Any())
IOperationGenerator (1)
IOperationClassWriter.cs (1)
277if (operationKinds.Any())
Microsoft.AspNetCore.App.Analyzers (2)
src\Shared\Roslyn\CodeAnalysisExtensions.cs (2)
16=> GetAttributes(typeSymbol, attribute, inherit).Any(); 19=> GetAttributes(methodSymbol, attribute, inherit).Any();
Microsoft.AspNetCore.Authentication (1)
src\Shared\SecurityHelper\SecurityHelper.cs (1)
42newPrincipal.AddIdentities(existingPrincipal.Identities.Where(i => i.IsAuthenticated || i.Claims.Any()));
Microsoft.AspNetCore.Authentication.JwtBearer (1)
JwtBearerConfigureOptions.cs (1)
38if (configSection is null || !configSection.GetChildren().Any())
Microsoft.AspNetCore.Authentication.OpenIdConnect (3)
OpenIdConnectConfigureOptions.cs (3)
38if (configSection is null || !configSection.GetChildren().Any()) 87if (cookieConfigSection is null || !cookieConfigSection.GetChildren().Any()) 113if (elementsFromConfig.Any())
Microsoft.AspNetCore.Authentication.Test (10)
CertificateTests.cs (7)
492if (actual.Any()) 502if (actual.Any()) 512if (actual.Any()) 522if (actual.Any()) 532if (actual.Any()) 542if (actual.Any()) 552if (actual.Any())
OpenIdConnect\TestSettings.cs (3)
69if (errors.Any()) 107if (errors.Any()) 146if (errors.Any())
Microsoft.AspNetCore.Authorization (5)
AuthorizationHandlerContext.cs (1)
79return !_failCalled && _succeedCalled && !PendingRequirements.Any();
AuthorizationPolicy.cs (2)
34if (!requirements.Any()) 121var anyPolicies = policies.Any();
ClaimsAuthorizationRequirement.cs (1)
32_emptyAllowedValues = AllowedValues == null || !AllowedValues.Any();
RolesAuthorizationRequirement.cs (1)
26if (!allowedRoles.Any())
Microsoft.AspNetCore.Authorization.Policy (1)
src\Shared\SecurityHelper\SecurityHelper.cs (1)
42newPrincipal.AddIdentities(existingPrincipal.Identities.Where(i => i.IsAuthenticated || i.Claims.Any()));
Microsoft.AspNetCore.Components (1)
Reflection\ComponentProperties.cs (1)
191!propertyInfo.GetCustomAttributes().OfType<CascadingParameterAttributeBase>().Any())
Microsoft.AspNetCore.Components.Analyzers.Tests (4)
Verifiers\CodeFixVerifier.cs (3)
89if (!actions.Any()) 106if (!allowNewCompilerDiagnostics && newCompilerDiagnostics.Any()) 121if (!analyzerDiagnostics.Any())
Verifiers\DiagnosticVerifier.cs (1)
113string diagnosticsOutput = actualResults.Any() ? FormatDiagnostics(analyzer, actualResults.ToArray()) : " NONE.";
Microsoft.AspNetCore.Components.Authorization.Tests (2)
AuthorizeRouteViewTest.cs (2)
235var nonEmptyDiff = batch.DiffsInOrder.Where(d => d.Edits.Any()).Single(); 353var diff = batch2.DiffsInOrder.Where(d => d.Edits.Any()).Single();
Microsoft.AspNetCore.Components.Endpoints (1)
Discovery\IRazorComponentApplication.cs (1)
32routes.Any())
Microsoft.AspNetCore.Components.Forms (2)
EditContext.cs (2)
203=> !GetValidationMessages(fieldIdentifier).Any(); 220return !GetValidationMessages().Any();
Microsoft.AspNetCore.Components.Performance (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Components.SdkAnalyzers.Tests (4)
Verifiers\CodeFixVerifier.cs (3)
89if (!actions.Any()) 106if (!allowNewCompilerDiagnostics && newCompilerDiagnostics.Any()) 121if (!analyzerDiagnostics.Any())
Verifiers\DiagnosticVerifier.cs (1)
113string diagnosticsOutput = actualResults.Any() ? FormatDiagnostics(analyzer, actualResults.ToArray()) : " NONE.";
Microsoft.AspNetCore.Components.Web (2)
Forms\FieldCssClassProvider.cs (1)
24var isValid = !editContext.GetValidationMessages(fieldIdentifier).Any();
Forms\InputBase.cs (1)
288if (EditContext.GetValidationMessages(FieldIdentifier).Any())
Microsoft.AspNetCore.Components.WebAssembly.Server (2)
Builder\WebAssemblyRazorComponentsEndpointConventionBuilderExtensions.cs (2)
38var needsCoopHeaders = endpointBuilder.Metadata.OfType<ComponentTypeMetadata>().Any() // e.g., /somecomponent 39|| endpointBuilder.Metadata.OfType<WebAssemblyRenderModeWithOptions>().Any(); // e.g., /_framework/*
Microsoft.AspNetCore.ConcurrencyLimiter.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.DataProtection (1)
XmlEncryption\XmlEncryptionExtensions.cs (1)
204return element.DescendantsAndSelf(XmlConstants.EncryptedSecretElementName).Any();
Microsoft.AspNetCore.DeveloperCertificates.XPlat (3)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
Microsoft.AspNetCore.Diagnostics (10)
DeveloperExceptionPage\Views\CompilationErrorPage.Designer.cs (3)
447if (frame.Line != 0 && frame.ContextCode.Any()) 464if (frame.PreContextCode.Any()) 551if (frame.PostContextCode.Any())
DeveloperExceptionPage\Views\ErrorPage.Designer.cs (7)
666if (frame.Line != 0 && frame.ContextCode.Any()) 683if (frame.PreContextCode.Any()) 770if (frame.PostContextCode.Any()) 872if (Model.Query.Any()) 959if (Model.Cookies.Any()) 1043if (Model.Headers.Any()) 1396if (Model.RouteValues != null && Model.RouteValues.Any())
Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore (8)
DatabaseDeveloperPageExceptionFilter.cs (2)
63if (registeredContexts.Any()) 77if (contextDetails.Any(c => c.PendingModelChanges || c.PendingMigrations.Any()))
DatabaseErrorPageMiddleware.cs (1)
100if (details != null && (details.PendingModelChanges || details.PendingMigrations.Any()))
Views\DatabaseErrorPage.Designer.cs (5)
185var contextWithNoDBOrMigrations = Model.ContextDetails.Where(c => !c.DatabaseExists && !c.PendingMigrations.Any()); 186if (contextWithNoDBOrMigrations.Any()) 286var contextWithPendingMigrations = Model.ContextDetails.Where(c => c.PendingMigrations.Any()).Except(contextWithNoDBOrMigrations); 287if (contextWithPendingMigrations.Any()) 479if (contextWithPendingModelChanges.Any())
Microsoft.AspNetCore.Grpc.JsonTranscoding (1)
src\Grpc\JsonTranscoding\src\Shared\HttpRoutePatternParser.cs (1)
343Debug.Assert(CurrentVariable.FieldPath.Any());
Microsoft.AspNetCore.Grpc.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Grpc.Swagger (1)
src\Grpc\JsonTranscoding\src\Shared\HttpRoutePatternParser.cs (1)
343Debug.Assert(CurrentVariable.FieldPath.Any());
Microsoft.AspNetCore.Hosting (3)
src\Shared\ErrorPage\ErrorPage.Designer.cs (3)
565if (frame.Line != 0 && frame.ContextCode.Any()) 582if (frame.PreContextCode.Any()) 669if (frame.PostContextCode.Any())
Microsoft.AspNetCore.Hosting.Tests (1)
WebHostTests.cs (1)
44Assert.False(serverAddressesFeature.Addresses.Any());
Microsoft.AspNetCore.Http.Abstractions.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Http.Connections (1)
src\Shared\SecurityHelper\SecurityHelper.cs (1)
42newPrincipal.AddIdentities(existingPrincipal.Identities.Where(i => i.IsAuthenticated || i.Claims.Any()));
Microsoft.AspNetCore.Http.Extensions (2)
RequestDelegateFactory.cs (1)
815else if (parameterCustomAttributes.OfType<AsParametersAttribute>().Any())
src\Shared\PropertyAsParameterInfo.cs (1)
205NullabilityState.Unknown => !_underlyingProperty.GetCustomAttributes().OfType<RequiredMemberAttribute>().Any(),
Microsoft.AspNetCore.Http.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Identity (1)
SignInManager.cs (1)
729if (externalLogin.AuthenticationTokens != null && externalLogin.AuthenticationTokens.Any())
Microsoft.AspNetCore.Identity.EntityFrameworkCore.Test (2)
src\Identity\test\Shared\ApiConsistencyTestBase.cs (2)
30nonVirtualMethods.Any(), 53missingSuffixMethods.Any(),
Microsoft.AspNetCore.Identity.InMemory.Test (3)
InMemoryStore.cs (1)
67return Task.FromResult<IList<TUser>>(Users.Where(u => (u.Roles.Where(x => x.RoleId == role.Id).Any())).Select(x => x).ToList());
src\Identity\test\Shared\ApiConsistencyTestBase.cs (2)
30nonVirtualMethods.Any(), 53missingSuffixMethods.Any(),
Microsoft.AspNetCore.Identity.Specification.Tests (2)
UserManagerSpecificationTests.cs (2)
1715Assert.True(!factors.Any()); 1811Assert.False(factors.Any());
Microsoft.AspNetCore.Identity.Test (2)
src\Identity\test\Shared\ApiConsistencyTestBase.cs (2)
30nonVirtualMethods.Any(), 53missingSuffixMethods.Any(),
Microsoft.AspNetCore.Identity.UI (1)
Areas\Identity\Filters\ExternalLoginsPageFilter.cs (1)
20var hasExternalLogins = schemes.Any();
Microsoft.AspNetCore.Mvc.Analyzers (3)
src\Shared\Roslyn\CodeAnalysisExtensions.cs (2)
16=> GetAttributes(typeSymbol, attribute, inherit).Any(); 19=> GetAttributes(methodSymbol, attribute, inherit).Any();
TopLevelParameterNameAnalyzer.cs (1)
86if (parameter.GetAttributes(symbolCache.FromBodyAttribute).Any())
Microsoft.AspNetCore.Mvc.Api.Analyzers (2)
src\Shared\Roslyn\CodeAnalysisExtensions.cs (2)
16=> GetAttributes(typeSymbol, attribute, inherit).Any(); 19=> GetAttributes(methodSymbol, attribute, inherit).Any();
Microsoft.AspNetCore.Mvc.ApiExplorer (3)
DefaultApiDescriptionProvider.cs (1)
271!defaultModelMetadata.Attributes.Attributes.OfType<IFromRouteMetadata>().Any())
EndpointMetadataApiDescriptionProvider.cs (1)
351if (responseMetadataTypes.Any())
src\Shared\PropertyAsParameterInfo.cs (1)
205NullabilityState.Unknown => !_underlyingProperty.GetCustomAttributes().OfType<RequiredMemberAttribute>().Any(),
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (1)
ApiResponseTypeProviderTest.cs (1)
764Assert.False(result.Any());
Microsoft.AspNetCore.Mvc.Core (9)
ApplicationModels\ApiBehaviorApplicationModelProvider.cs (2)
119if (controller.Attributes.OfType<IApiBehaviorMetadata>().Any()) 126return assemblyAttributes.OfType<IApiBehaviorMetadata>().Any();
ApplicationModels\ConsumesConstraintForFormFileParameterConvention.cs (1)
43if (action.Filters.OfType<IConsumesActionConstraint>().Any())
DependencyInjection\MvcCoreServiceCollectionExtensions.cs (1)
66if (!manager.FeatureProviders.OfType<ControllerFeatureProvider>().Any())
ModelBinding\Binders\CollectionModelBinder.cs (1)
151if (bindingContext.ModelMetadata.HasDefaultValue && (boundCollection is null || !boundCollection.Any()))
MvcCoreLoggerExtensions.cs (1)
252if (filters.Any())
Routing\ActionEndpointFactory.cs (2)
419!builder.Metadata.OfType<HttpMethodMetadata>().Any()) 424!builder.Metadata.OfType<AcceptsMetadata>().Any())
src\Shared\SecurityHelper\SecurityHelper.cs (1)
42newPrincipal.AddIdentities(existingPrincipal.Identities.Where(i => i.IsAuthenticated || i.Claims.Any()));
Microsoft.AspNetCore.Mvc.Cors (4)
CorsApplicationModelProvider.cs (4)
42var isCorsEnabledGlobally = context.Result.Filters.OfType<ICorsAuthorizationFilter>().Any() || 43context.Result.Filters.OfType<CorsAuthorizationFilterFactory>().Any(); 59var corsOnController = enableCors != null || disableCors != null || controllerModel.Filters.OfType<ICorsAuthorizationFilter>().Any(); 75var corsOnAction = enableCors != null || disableCors != null || actionModel.Filters.OfType<ICorsAuthorizationFilter>().Any();
Microsoft.AspNetCore.Mvc.DataAnnotations (1)
ValidatableObjectAdapter.cs (1)
51if (result.MemberNames == null || !result.MemberNames.Any())
Microsoft.AspNetCore.Mvc.Razor (4)
DependencyInjection\MvcRazorMvcCoreBuilderExtensions.cs (2)
66if (!partManager.FeatureProviders.OfType<TagHelperFeatureProvider>().Any()) 71if (!partManager.FeatureProviders.OfType<RazorCompiledItemFeatureProvider>().Any())
RazorView.cs (2)
283if (originalLocations!.Any()) 288if (layoutPageResult.SearchedLocations.Any())
Microsoft.AspNetCore.Mvc.RazorPages (1)
ApplicationModels\AutoValidateAntiforgeryPageApplicationModelProvider.cs (1)
29if (!pageApplicationModel.Filters.OfType<IAntiforgeryPolicy>().Any())
Microsoft.AspNetCore.Mvc.TagHelpers.Test (2)
GlobbingUrlBuilderTest.cs (2)
445public bool IsDirectory => Children != null && Children.Any(); 458if (rootNode.Children == null || !rootNode.Children.Any())
Microsoft.AspNetCore.Mvc.ViewFeatures (12)
Builder\ControllerActionEndpointConventionBuilderResourceCollectionExtensions.cs (1)
45if (endpointBuilder.Metadata.OfType<ApiControllerAttribute>().Any())
DependencyInjection\MvcViewFeaturesMvcCoreBuilderExtensions.cs (1)
64if (!manager.FeatureProviders.OfType<ViewComponentFeatureProvider>().Any())
Filters\AntiforgeryApplicationModelProvider.cs (2)
56if (antiforgeryAttribute is not null && antiforgeryMetadata.Any()) 60return antiforgeryMetadata.Any();
HtmlHelper.cs (2)
525if (originalLocations.Any()) 530if (viewEngineResult.SearchedLocations.Any())
PartialViewResultExecutor.cs (2)
81if (originalResult.SearchedLocations.Any()) 83if (result.SearchedLocations.Any())
ViewEngines\ViewEngineResult.cs (2)
96if (originalLocations != null && originalLocations.Any()) 101if (SearchedLocations.Any())
ViewResultExecutor.cs (2)
82if (originalResult.SearchedLocations.Any()) 84if (result.SearchedLocations.Any())
Microsoft.AspNetCore.OpenApi (2)
Extensions\ApiDescriptionExtensions.cs (1)
96return formParameters.Any();
src\Shared\PropertyAsParameterInfo.cs (1)
205NullabilityState.Unknown => !_underlyingProperty.GetCustomAttributes().OfType<RequiredMemberAttribute>().Any(),
Microsoft.AspNetCore.OpenApi.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.OutputCaching (2)
CacheVaryByRules.cs (1)
16internal bool HasVaryByValues => _varyByValues != null && _varyByValues.Any();
OutputCachePolicyBuilder.cs (1)
330if (_requirements != null && _requirements.Any())
Microsoft.AspNetCore.OutputCaching.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.RequestDecompression.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.ResponseCaching.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.ResponseCompression (1)
ResponseCompressionProvider.cs (1)
57if (mimeTypes == null || !mimeTypes.Any())
Microsoft.AspNetCore.ResponseCompression.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Rewrite (1)
IISUrlRewrite\UrlRewriteFileParser.cs (1)
114if (!adds.Any())
Microsoft.AspNetCore.Routing (4)
Template\RoutePrecedence.cs (2)
166if (part.InlineConstraints != null && part.InlineConstraints.Any()) 236if (part.InlineConstraints != null && part.InlineConstraints.Any())
Tree\UrlMatchingTree.cs (2)
139if (part.IsParameter && part.InlineConstraints.Any() && !part.IsCatchAll) 161if (part.IsParameter && part.InlineConstraints.Any() && part.IsCatchAll)
Microsoft.AspNetCore.Routing.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Security.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (1)
RequestTests.cs (1)
398Assert.False(errorLogs.Any(), string.Join(" ", errorLogs));
Microsoft.AspNetCore.Server.HttpSys.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Server.IIS (3)
src\Shared\ErrorPage\ErrorPage.Designer.cs (3)
565if (frame.Line != 0 && frame.ContextCode.Any()) 582if (frame.PreContextCode.Any()) 669if (frame.PostContextCode.Any())
Microsoft.AspNetCore.Server.IntegrationTesting (6)
CachingApplicationPublisher.cs (1)
23if (deploymentParameters.PublishEnvironmentVariables.Any())
TestMatrix.cs (5)
94if (!Servers.Any()) 100if (!Tfms.Any()) 107if (!ApplicationTypes.Any()) 112if (!HostingModels.Any()) 127if (!Architectures.Any())
Microsoft.AspNetCore.Server.IntegrationTesting.IIS (5)
IISDeployer.cs (2)
189if (!lines.Any()) 360if (DeploymentParameters.EnvironmentVariables.Any())
IISDeployerBase.cs (3)
33if (!actions.Any()) 56if (IISDeploymentParameters.HandlerSettings.Any()) 61if (IISDeploymentParameters.WebConfigBasedEnvironmentVariables.Any())
Microsoft.AspNetCore.Server.Kestrel.Core (4)
CertificateLoader.cs (1)
110=> certificate.Extensions.OfType<X509SubjectAlternativeNameExtension>().Any();
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (2)
src\Servers\Kestrel\shared\KnownHeaders.cs (2)
310return values.Any() ? values.Select(formatter).Aggregate((a, b) => a + b) : ""; 315return values.Any() ? values.Select(formatter).Aggregate((a, b) => a + b) : "";
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.Session.Tests (2)
SessionTests.cs (2)
657Assert.False(context.Session.Keys.Any()); 707Assert.False(context.Session.Keys.Any());
Microsoft.AspNetCore.Shared.Tests (6)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
src\Shared\SecurityHelper\SecurityHelper.cs (1)
42newPrincipal.AddIdentities(existingPrincipal.Identities.Where(i => i.IsAuthenticated || i.Claims.Any()));
Microsoft.AspNetCore.SignalR.Core (2)
HubOptionsSetup.cs (1)
35if (hubProtocol.GetType().CustomAttributes.Where(a => a.AttributeType.FullName == "Microsoft.AspNetCore.SignalR.Internal.NonDefaultHubProtocolAttribute").Any())
Internal\HubMethodDescriptor.cs (1)
80else if (p.CustomAttributes.Any())
Microsoft.AspNetCore.SignalR.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.TestHost (1)
WebSocketClient.cs (1)
83if (SubProtocols.Any())
Microsoft.AspNetCore.TestHost.Tests (1)
TestClientTests.cs (1)
662var subprotocols = ctx.WebSockets.WebSocketRequestedProtocols.Any()
Microsoft.AspNetCore.WebSockets.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.AspNetCore.WebUtilities.Microbenchmarks (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.Build (23)
BackEnd\Components\Logging\LoggingService.cs (1)
591bool allSinksIncludeEvalData = sinks.Any() && sinks.All(sink => sink.IncludeEvaluationPropertiesAndItems);
BackEnd\Components\ProjectCache\ProjectCacheService.cs (1)
421return GetProjectCacheDescriptors(buildRequestConfiguration.Project).Any();
BackEnd\Components\RequestBuilder\RequestBuilder.cs (1)
244ErrorUtilities.VerifyThrow(_pendingResourceRequests.Any(), "No pending resource requests");
BackEnd\Components\RequestBuilder\TargetBuilder.cs (2)
409_targetsToBuild.Any()) 614while ((_targetsToBuild.Any()) && (_targetsToBuild.Peek() != topEntry.ParentEntry) && !_targetsToBuild.Peek().ErrorTarget)
BackEnd\Components\RequestBuilder\TargetUpToDateChecker.cs (1)
868if (GetItemSpecsFromItemVectors(itemVectors, item.Key, item.Value).Any())
BackEnd\Components\SdkResolution\SdkResolverService.cs (2)
374string resultWarnings = result.Warnings?.Any() == true ? string.Join(Environment.NewLine, result.Warnings) : "null"; 375string resultErrors = result.Errors?.Any() == true ? string.Join(Environment.NewLine, result.Errors) : "null";
BuildCheck\Infrastructure\BuildCheckManagerProvider.cs (1)
201if (instance != null && instance.SupportedRules.Any())
BuildCheck\Infrastructure\ConfigurationProvider.cs (2)
65if (!configuration.Any()) 239if (config.Any())
Definition\Project.cs (2)
3443if ((metadata?.Any() == true) || candidateExistingItemXml.Count > 0) 3847if (metadata?.Any() == true)
Evaluation\Evaluator.cs (4)
1853if ((sdkResult.PropertiesToAdd?.Any() == true) || 1854(sdkResult.ItemsToAdd?.Any() == true)) 1923if (sdkResult.PropertiesToAdd?.Any() == true) 1932if (sdkResult.ItemsToAdd?.Any() == true)
Evaluation\LazyItemEvaluator.RemoveOperation.cs (2)
32if (_matchOnMetadata.Any()) 51bool matchingOnMetadata = _matchOnMetadata.Any();
Instance\ReflectableTaskPropertyInfo.cs (2)
49propertyInfo.GetCustomAttributes(typeof(OutputAttribute), true).Any(), 50propertyInfo.GetCustomAttributes(typeof(RequiredAttribute), true).Any())
Logging\ProfilerLogger.cs (1)
137while (_profiledResults.Any())
Utilities\EngineFileUtilities.cs (1)
197var excludeSpecsAreEmpty = excludeSpecsEscaped?.Any() != true;
Microsoft.Build.BuildCheck.UnitTests (2)
EndToEndTests.cs (2)
685if (ruleToSeverity != null && ruleToSeverity.Any()) 696if (ruleToCustomConfig != null && ruleToCustomConfig.Any())
Microsoft.Build.Engine.OM.UnitTests (3)
Instance\ProjectInstance_Tests.cs (3)
442Assert.False(projAInstanceItem.Metadata.Any()); 484Assert.False(projAInstanceItem.Metadata.Any()); 519Assert.False(projAInstanceItem.Metadata.Any());
Microsoft.Build.Framework (2)
EncodingUtilities.cs (1)
163return bytesRead == preamble.Length && !buffer.Where((t, i) => preamble[i] != t).Any();
Profiler\ProfilerResult.cs (1)
38!ProfiledLocations.Except(result.ProfiledLocations).Any());
Microsoft.Build.Tasks.CodeAnalysis.UnitTests (1)
IntegrationTests.cs (1)
47if (!vars.Where(kvp => kvp.Key == "RoslynCommandLineLogFile").Any())
Microsoft.Build.Tasks.Core (1)
GetSDKReferenceFiles.cs (1)
282if (_exceptions.Any() && LogCacheFileExceptions)
Microsoft.Build.Utilities.Core (1)
ToolLocationHelper.cs (1)
1462if (folders.Any())
Microsoft.Build.Utilities.UnitTests (4)
ToolLocationHelper_Tests.cs (4)
3997ToolLocationHelper.GetPlatformsForSDK("AnySDK", new Version("1.0"), Array.Empty<string>(), "").Any().ShouldBeFalse(); 4021ToolLocationHelper.GetPlatformsForSDK("DoesNotExistPlatform", new Version("0.0.0.0"), new[] { _fakeStructureRoot }, null).Any().ShouldBeFalse(); 4031ToolLocationHelper.GetPlatformsForSDK("MyPlatform", new Version("0.0.0.0"), new[] { _fakeStructureRoot }, null).Any().ShouldBeFalse(); 4041ToolLocationHelper.GetPlatformsForSDK("Windows", new Version("8.0"), new[] { _fakeStructureRoot }, null).Any().ShouldBeFalse();
Microsoft.Cci.Extensions (18)
Differs\IDifferences.cs (1)
21return !differences.OfType<IncompatibleDifference>().Any();
Extensions\CSharp\CSharpCciExtensions.cs (3)
297return MemberHelper.GetImplicitlyImplementedInterfaceMethods(method).Any() 298|| MemberHelper.GetExplicitlyOverriddenMethods(method).Any(); 866if (foundInterfaces.Any())
Extensions\TypeExtensions.cs (1)
504return assembly.ExportedTypes.Any();
Filters\MappingDifferenceFilter.cs (2)
24if (assembly.Namespaces.Any() && Include(assembly.Difference)) 32if (ns.Types.Any() && Include(ns.Difference))
Filters\NotImplementedFilter.cs (1)
24var hasOnlyExcludedMembers = type.Members.Any() && type.Members.All(m => !Include(m));
Writers\CSharp\CSDeclarationWriter.Attributes.cs (2)
110if (!attributes.Any()) 152if (attribute.NumberOfNamedArguments > 0 || attribute.Arguments.Any() || action != SecurityAction.ActionNil)
Writers\CSharp\CSDeclarationWriter.Generics.cs (2)
17if (!genericParameters.Any()) 39if (!genericParams.Any())
Writers\CSharp\CSDeclarationWriter.Methods.cs (1)
204if (parameters.Any())
Writers\CSharp\CSDeclarationWriter.Types.cs (3)
99if (baseType == null && !interfaces.Any()) 108if (interfaces.Any()) 119if (interfaces.Any())
Writers\CSharp\CSharpWriter.cs (2)
171if (!type.IsStatic && !constructors.Any()) 228if (excludedFields.Any())
Microsoft.CodeAnalysis (17)
CommandLine\CommonCompiler.cs (1)
639if (enumerable.Any())
Compilation\Compilation.cs (2)
2131if (Options.OutputKind == OutputKind.NetModule && !(manifestResources != null && manifestResources.Any())) 2138if (manifestResources != null && manifestResources.Any())
Diagnostic\DiagnosticBag.cs (1)
39/// This exists for short-circuiting purposes. Use <see cref="System.Linq.Enumerable.Any{T}(IEnumerable{T})"/>
DiagnosticAnalyzer\AnalysisResult.cs (1)
91var excludedAnalyzersSet = excludedAnalyzers.Any() ? excludedAnalyzers.ToImmutableHashSet() : ImmutableHashSet<DiagnosticAnalyzer>.Empty;
DiagnosticAnalyzer\AnalyzerExecutor.cs (9)
767Debug.Assert(startActions.Any() || endActions.Any() || actions.Any()); 853ExecuteSyntaxNodeActions(syntaxNodesToAnalyze, executableNodeActionsByKind, analyzer, declaredSymbol, semanticModel, getKind, diagReporter, isSupportedDiagnostic, filterSpan, isGeneratedCode, hasCodeBlockStartOrSymbolStartActions: startActions.Any(), cancellationToken); 859ExecuteOperationActions(operationsToAnalyze, operationActionsByKind, analyzer, declaredSymbol, semanticModel, diagReporter, isSupportedDiagnostic, filterSpan, isGeneratedCode, hasOperationBlockStartOrSymbolStartActions: startActions.Any(), cancellationToken); 928Debug.Assert(nodeActions != null && nodeActions.Any()); 995Debug.Assert(nodeActionsByKind.Any()); 1027Debug.Assert(operationActions.Any()); 1095Debug.Assert(operationActionsByKind.Any());
PEWriter\PeWriter.cs (2)
385if (nativeResourcesOpt?.Any() == true) 421Debug.Assert(resources.Any());
Text\SourceText.cs (1)
755if (!changes.Any())
Microsoft.CodeAnalysis.CodeStyle (10)
src\Analyzers\Core\Analyzers\MatchFolderAndNamespace\AbstractMatchFolderAndNamespaceDiagnosticAnalyzer.cs (2)
98if (namespaceDeclaration.Ancestors().OfType<TNamespaceSyntax>().Any()) 106.OfType<TNamespaceSyntax>().Any();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\INamedTypeSymbolExtensions.cs (1)
340if (!interfacesOrAbstractClasses.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SyntaxNodeExtensions.cs (2)
100return node.GetAncestors<TNode>().Any(); 299Contract.ThrowIfFalse(nodes.Any());
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
397if (!words.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AnnotationTable.cs (4)
148=> this.GetAnnotations(node).OfType<TSpecificAnnotation>().Any(); 151=> this.GetAnnotations(token).OfType<TSpecificAnnotation>().Any(); 154=> this.GetAnnotations(trivia).OfType<TSpecificAnnotation>().Any(); 157=> this.GetAnnotations(nodeOrToken).OfType<TSpecificAnnotation>().Any();
Microsoft.CodeAnalysis.CodeStyle.Fixes (8)
src\Analyzers\Core\CodeFixes\DocumentationComments\AbstractAddDocCommentNodesCodeFixProvider.cs (2)
84if (index != 0 || (!paramNodes.Any() && summaryNode != null)) 133if (!nodes.Any())
src\Analyzers\Core\CodeFixes\GenerateParameterizedMember\TypeParameterSubstitution.cs (1)
118if (similarTypes.Any())
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.State.cs (1)
146if (existingMembers.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ProjectExtensions.cs (1)
56if (project.AnalyzerConfigDocuments.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\SyntaxEditorExtensions.cs (1)
166var nodesToVerify = nodesBySemanticBoundary.Where(group => group.Skip(1).Any()).Flatten().ToSet();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Simplification\AbstractSimplificationService.cs (2)
145if (reducedNodesMap.Any() || reducedTokensMap.Any())
Microsoft.CodeAnalysis.CSharp (19)
Binder\Binder_Statements.cs (2)
2582if (stack.Any()) 2588while (stack.Any());
Binder\DecisionDagBuilder.cs (4)
1113if (whenTruePossible && !whenTrueState.IsImpossible && !(whenTrueBuilder.Any() && whenTrueBuilder.Last().IsFullyMatched)) 1116if (whenFalsePossible && !whenFalseState.IsImpossible && !(whenFalseBuilder.Any() && whenFalseBuilder.Last().IsFullyMatched)) 1684result.AppendLine($"{(remainingValues.Any() ? " REMAINING " + string.Join(" ", remainingValues) : "")}"); 1717if (bindings.Any())
Binder\Semantics\OverloadResolution\MemberAnalysisResult.cs (1)
324Debug.Assert(badArguments.TrueBits().Any());
Compilation\SyntaxAndDeclarationManager.cs (2)
568if (newLoadDirectivesSyntax.Any()) 725return state.DeclarationTable.ReferenceDirectives.Any();
Compiler\MethodCompiler.cs (2)
2218if (body1?.DescendantNodesAndSelf().Where(n => (object)n == _id).Any() == true || 2219body2?.DescendantNodesAndSelf().Where(n => (object)n == _id).Any() == true)
Emitter\Model\PEModuleBuilder.cs (2)
1564if (!flagsBuilder.Any()) 1652Debug.Assert(builder.Any());
Lowering\ClosureConversion\ClosureConversion.cs (1)
811primaryConstructor.GetCapturedParameters().Any());
Operations\CSharpOperationFactory.cs (1)
1838while (stack.Any());
Symbols\MetadataOrSourceAssemblySymbol.cs (1)
241if (publicKeys.Any() && this.IsNetModule())
Symbols\PublicModel\AssemblySymbol.cs (1)
72if (myKeys.Any())
Symbols\Source\SourceMemberContainerSymbol.cs (2)
2778PrimaryConstructor is { } primaryConstructor && primaryConstructor.GetCapturedParameters().Any() && 4183Debug.Assert(declaredMembersAndInitializers.PrimaryConstructor?.GetBackingFields().Any() != true);
Microsoft.CodeAnalysis.CSharp.CodeStyle (9)
src\Analyzers\CSharp\Analyzers\QualifyMemberAccess\CSharpQualifyMemberAccessDiagnosticAnalyzer.cs (1)
65=> declarationSyntax.GetAncestorsOrThis(n => n.IsKind(SyntaxKind.FieldDeclaration) && n.Contains(node)).Any();
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryImports\CSharpRemoveUnnecessaryImportsDiagnosticAnalyzer.cs (1)
53Contract.ThrowIfFalse(nodes.Any());
src\Analyzers\CSharp\Analyzers\UseUtf8StringLiteral\UseUtf8StringLiteralDiagnosticAnalyzer.cs (1)
82if (arrayCreationOperation.Syntax.Ancestors().OfType<AttributeSyntax>().Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTriviaExtensions.cs (1)
123if (trivia.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\ElasticTriviaFormattingRule.cs (2)
45basePropertyDeclaration.GetAnnotatedTrivia(SyntaxAnnotation.ElasticAnnotation).Any()) 121if (previousToken.Parent.Ancestors().OfType<TypeParameterConstraintClauseSyntax>().Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Utilities\SpeculationAnalyzer.cs (3)
225if (!paramNames.Any()) 256if (!originalIdentifierNodes.Any()) 277Debug.Assert(originalIdentifierNodes.Any());
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (3)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\CSharpCodeGenerationHelpers.cs (1)
195=> declaration.ChildTokens().Where(t => t.Kind() is SyntaxKind.OpenBraceToken or SyntaxKind.CloseBraceToken && t.IsMissing).Any();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\CompilationUnitSyntaxExtensions.cs (1)
96if (!usingDirectives.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
556if (indexers.Any())
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (2)
Debugging\DataTipInfoGetterTests.cs (1)
50var expectedSpan = testHostDocument.SelectedSpans.Any()
EncapsulateField\EncapsulateFieldTestState.cs (1)
34_testDocument = Workspace.Documents.Single(d => d.CursorPosition.HasValue || d.SelectedSpans.Any());
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (23)
Attributes\AttributeTests_WellKnownAttributes.cs (1)
8851if (expectedDiagnostics.Any())
FlowAnalysis\FlowTestBase.cs (1)
234return symbols.Any() ? string.Join(", ", symbols.Select(symbol => symbol.Name)) : null;
Semantics\OutVarTests.cs (21)
178Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 386Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 423Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 461Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 499Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 537Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 575Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 622Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 659Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 697Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 737Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 776Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 816Assert.False(compilation.SyntaxTrees.Single().GetRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any()); 1303decl.Ancestors().OfType<DoStatementSyntax>(), d => d, d => d, (d1, d2) => true).Any()))) 2472Assert.False(GetOutVarDeclarations(tree, "x3").Any()); 2473Assert.False(GetOutVarDeclarations(tree, "x4").Any()); 2474Assert.False(GetOutVarDeclarations(tree, "x5").Any()); 2475Assert.False(GetOutVarDeclarations(tree, "x6").Any()); 17832Assert.False(GetOutVarDeclarations(tree).Any()); 17893Assert.False(GetOutVarDeclarations(tree).Any()); 23056Assert.False(GetOutVarDeclarations(tree, "x3").Any());
Microsoft.CodeAnalysis.CSharp.Features (18)
CodeRefactorings\SyncNamespace\CSharpChangeNamespaceService.cs (1)
391.OfType<BaseNamespaceDeclarationSyntax>().Any();
Completion\CompletionProviders\NamedParameterCompletionProvider.cs (2)
95if (!unspecifiedParameters.Any()) 260if (methodGroup.Any())
ConvertLinq\CSharpConvertLinqQueryToForEachProvider.cs (4)
798if (stack.Any()) 813while (stack.Any()) 818isLastClause: !stack.Any(), 819hasExtraDeclarations: statements.Any(),
DecompiledSource\CSharpDecompiledSourceService.cs (1)
123if (containingTypeStack.Any())
EditAndContinue\DeclarationBody\CSharpLambdaBody.cs (1)
33HasSuspensionPoints: SyntaxUtilities.GetSuspensionPoints(node).Any());
EditAndContinue\DeclarationBody\SimpleMemberBody.cs (1)
28HasSuspensionPoints: SyntaxUtilities.GetSuspensionPoints(Node).Any());
EditAndContinue\DeclarationBody\TopLevelCodeDeclarationBody.cs (1)
43var isAsync = GlobalStatements.Any(static s => SyntaxUtilities.GetSuspensionPoints(s).Any());
ExtractMethod\CSharpMethodExtractor.Analyzer.cs (1)
53=> jumpOutOfRegionStatements.Where(n => n is ReturnStatementSyntax).Any();
ExtractMethod\CSharpSelectionValidator.cs (1)
446=> jumpsOutOfRegion.Where(n => n is not ReturnStatementSyntax).Any();
ExtractMethod\Extensions.cs (1)
234=> set.Any(a => node.GetAnnotatedNodesAndTokens(a).Any());
SignatureHelp\TupleConstructionSignatureHelpProvider.cs (2)
117if (inferredTypes == null || !inferredTypes.Any()) 138if (tupleTypes.Any())
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryImports\CSharpRemoveUnnecessaryImportsDiagnosticAnalyzer.cs (1)
53Contract.ThrowIfFalse(nodes.Any());
src\Analyzers\CSharp\Analyzers\UseUtf8StringLiteral\UseUtf8StringLiteralDiagnosticAnalyzer.cs (1)
82if (arrayCreationOperation.Syntax.Ancestors().OfType<AttributeSyntax>().Any())
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (11)
Semantics\BindingTests.cs (6)
3399Assert.False(symbols.Where(s => s.Name == "MathMin").Any()); 3400Assert.True(symbols.Where(s => s.Name == "MathMax").Any()); 3401Assert.True(symbols.Where(s => s.Name == "F1").Any()); 3402Assert.False(symbols.Where(s => s.Name == "F2").Any()); 3403Assert.False(symbols.Where(s => s.Name == "MathMax2").Any()); 3404Assert.False(symbols.Where(s => s.Name == "MathMax3").Any());
Semantics\ConditionalOperatorTests.cs (1)
1301if (!expectedDiagnostics.Any())
Semantics\DeconstructionTests.cs (1)
5130Assert.False(tree.GetCompilationUnitRoot().DescendantNodes().OfType<DeclarationExpressionSyntax>().Any());
Semantics\InterpolationTests.cs (1)
4602.Where(b => b.DescendantNodes().OfType<InterpolatedStringExpressionSyntax>().Any())
Semantics\RawInterpolationTests_Handler.cs (1)
2903.Where(b => b.DescendantNodes().OfType<InterpolatedStringExpressionSyntax>().Any())
Semantics\TargetTypedConditionalOperatorTests.cs (1)
361if (!expectedDiagnostics.Any())
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (1)
Symbols\CorLibrary\CorTypes.cs (1)
132Assert.Equal(knownMissingTypes.Any(), msCorLibRef.KeepLookingForDeclaredSpecialTypes);
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (2)
Parsing\MemberDeclarationParsingTests.cs (2)
78if (d.GetDiagnostics().Any()) // some platforms have extra deep stacks and can parse this 104if (cu.GetDiagnostics().Any()) // some platforms have extra deep stacks and can parse this
Microsoft.CodeAnalysis.CSharp.Test.Utilities (2)
CSharpTestBase.cs (2)
1086if (sources == null || !sources.Any()) 1337bool hasTopLevelStatements = syntaxTrees.Any(s => s.GetRoot().ChildNodes().OfType<GlobalStatementSyntax>().Any());
Microsoft.CodeAnalysis.CSharp.Workspaces (10)
Rename\CSharpRenameRewriterLanguageService.cs (1)
298var expandParameter = !originalNode.GetAncestorsOrThis(n => n is SimpleLambdaExpressionSyntax or ParenthesizedLambdaExpressionSyntax).Any();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\SyntaxTriviaExtensions.cs (1)
123if (trivia.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\Rules\ElasticTriviaFormattingRule.cs (2)
45basePropertyDeclaration.GetAnnotatedTrivia(SyntaxAnnotation.ElasticAnnotation).Any()) 121if (previousToken.Parent.Ancestors().OfType<TypeParameterConstraintClauseSyntax>().Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Utilities\SpeculationAnalyzer.cs (3)
225if (!paramNames.Any()) 256if (!originalIdentifierNodes.Any()) 277Debug.Assert(originalIdentifierNodes.Any());
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\CodeGeneration\CSharpCodeGenerationHelpers.cs (1)
195=> declaration.ChildTokens().Where(t => t.Kind() is SyntaxKind.OpenBraceToken or SyntaxKind.CloseBraceToken && t.IsMissing).Any();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\CompilationUnitSyntaxExtensions.cs (1)
96if (!usingDirectives.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpTypeInferenceService.TypeInferrer.cs (1)
556if (indexers.Any())
Microsoft.CodeAnalysis.EditorFeatures (41)
CodeActions\CodeActionEditHandlerService.cs (14)
199if (changes.GetAddedProjects().Any() || 200changes.GetRemovedProjects().Any()) 212if (projectChange.GetAddedAdditionalDocuments().Any() || 213projectChange.GetAddedAnalyzerReferences().Any() || 214projectChange.GetAddedDocuments().Any() || 215projectChange.GetAddedAnalyzerConfigDocuments().Any() || 216projectChange.GetAddedMetadataReferences().Any() || 217projectChange.GetAddedProjectReferences().Any() || 218projectChange.GetRemovedAdditionalDocuments().Any() || 219projectChange.GetRemovedAnalyzerReferences().Any() || 220projectChange.GetRemovedDocuments().Any() || 221projectChange.GetRemovedAnalyzerConfigDocuments().Any() || 222projectChange.GetRemovedMetadataReferences().Any() || 223projectChange.GetRemovedProjectReferences().Any())
EditorConfigSettings\Updater\NamingStyles\NamingStyleSettingsUpdater.cs (1)
30if (!result.Rules.Any() && settingsToUpdate.Any())
EditorConfigSettings\Updater\NamingStyles\SourceTextExtensions.cs (1)
35if (rules.Any())
EditorConfigSettings\Updater\SettingsUpdaterBase.cs (1)
110return _queue.Any();
InlineRename\AbstractEditorInlineRenameService.InlineRenameReplacementInfo.cs (1)
47if (modifiedSpans.Any())
InlineRename\AbstractEditorInlineRenameService.SymbolRenameInfo.cs (1)
66this.HasOverloads = RenameUtilities.GetOverloadedSymbols(this.RenameSymbol).Any();
InlineRename\AbstractInlineRenameUndoManager.cs (2)
126if (!this.UndoStack.Any()) 190if (!edit.HasEffectiveChanges && !this.UndoStack.Any())
InlineRename\InlineRenameSession.cs (2)
246if (!selections.Any() || 602if (documents.Any())
InlineRename\InlineRenameSession.OpenTextBufferManager.cs (1)
440if (!relevantReplacements.Any())
Interactive\SendToInteractiveSubmissionProvider.cs (1)
74return newSpans.Any() ? newSpans : selectedSpans;
Preview\AbstractPreviewFactoryService.cs (2)
582if (!(originalSpans.Any() && changedSpans.Any()))
Preview\SolutionChangeSummary.cs (12)
36if (p.GetAddedDocuments().Any() || p.GetRemovedDocuments().Any() || 37p.GetAddedAdditionalDocuments().Any() || p.GetRemovedAdditionalDocuments().Any() || 38p.GetAddedAnalyzerConfigDocuments().Any() || p.GetRemovedAnalyzerConfigDocuments().Any() || 39p.GetAddedMetadataReferences().Any() || p.GetRemovedMetadataReferences().Any() || 40p.GetAddedProjectReferences().Any() || p.GetRemovedProjectReferences().Any() || 41p.GetAddedAnalyzerReferences().Any() || p.GetRemovedAnalyzerReferences().Any())
Shared\Extensions\ITextViewExtensions.PerSubjectBufferProperty.cs (2)
148if (!bufferMap.Any()) 157if (!bufferMap.Any())
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (12)
CodeLens\AbstractCodeLensTest.cs (4)
23foreach (var annotatedDocument in workspace.Documents.Where(d => d.AnnotatedSpans.Any())) 51foreach (var annotatedDocument in workspace.Documents.Where(d => d.AnnotatedSpans.Any())) 77foreach (var annotatedDocument in workspace.Documents.Where(d => d.AnnotatedSpans.Any())) 103foreach (var annotatedDocument in workspace.Documents.Where(d => d.AnnotatedSpans.Any()))
CompleteStatement\AbstractCompleteStatementTests.cs (2)
103Assert.True(testDocument.CursorPosition.HasValue || testDocument.SelectedSpans.Any(), "No caret position or selected spans are set!"); 108if (testDocument.SelectedSpans.Any())
DocumentationComments\AbstractDocumentationCommentTests.cs (1)
148if (testDocument.SelectedSpans.Any())
SignatureHelp\AbstractSignatureHelpProviderTests.cs (5)
359if (selectedSpans.Any()) 365if (textSpans != null && textSpans.Any()) 402if ((expectedOrderedItemsOrNull == null || !expectedOrderedItemsOrNull.Any()) && items == null) 476if (selectedSpans.Any()) 482if (textSpans != null && textSpans.Any())
Microsoft.CodeAnalysis.EditorFeatures.Text (1)
Extensions.SnapshotSourceText.cs (1)
192if (!changes.Any())
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (2)
MetadataAsSource\AbstractMetadataAsSourceTests.TestContext.cs (1)
50metadataSources = !metadataSources.Any()
Options\GlobalOptionsTests.cs (1)
113if (property.GetCustomAttributes<DataMemberAttribute>().Any())
Microsoft.CodeAnalysis.EditorFeatures.Wpf (3)
InlineRename\CommandHandlers\RenameCommandHandler.cs (1)
85return adornment.Elements.Any()
InlineRename\UI\InlineRenameAdornmentManager.cs (1)
179.Any();
InlineRename\UI\InlineRenameAdornmentProvider.cs (1)
94if (textView.BufferGraph.GetTextBuffers(b => b.ContentType.IsOfType(ContentTypeNames.RoslynContentType)).Any())
Microsoft.CodeAnalysis.ExternalAccess.FSharp (1)
SignatureHelp\FSharpSignatureHelpItem.cs (1)
50if (isVariadic && !parameters.Any())
Microsoft.CodeAnalysis.ExternalAccess.Xaml (1)
Internal\DescriptionService.cs (1)
72if (builder.Any())
Microsoft.CodeAnalysis.Features (29)
AddConstructorParametersFromMembers\AddConstructorParametersFromMembersCodeRefactoringProvider.State.cs (1)
118!parameterNamesForSelectedMembers.Except(constructorParams.Select(p => p.Name)).Any();
CodeFixes\Suppression\AbstractSuppressionBatchFixAllProvider.cs (2)
49if (documentsAndDiagnosticsToFixMap?.Any() == true) 142if (projectsAndDiagnosticsToFixMap != null && projectsAndDiagnosticsToFixMap.Any())
CodeFixes\Suppression\AbstractSuppressionCodeFixProvider.GlobalSuppressMessageFixAllCodeAction.cs (2)
84if (diagnosticsBySymbol.Any()) 112if (diagnosticsBySymbol.Any())
CodeRefactorings\MoveType\AbstractMoveTypeService.cs (1)
181=> TopLevelTypeDeclarations(root).Skip(1).Any();
CodeRefactorings\MoveType\AbstractMoveTypeService.MoveTypeNamespaceScopeEditor.cs (1)
111if (syntaxNodes.Any())
CodeRefactorings\SyncNamespace\AbstractSyncNamespaceCodeRefactoringProvider.MoveFileCodeAction.cs (1)
140if (!folder.Any())
Completion\Providers\AbstractPartialMethodCompletionProvider.cs (1)
55if (items?.Any() == true)
ExternalAccess\UnitTesting\SolutionCrawler\UnitTestingWorkCoordinator.cs (6)
432if (projectChanges.GetAddedMetadataReferences().Any() || 433projectChanges.GetAddedProjectReferences().Any() || 434projectChanges.GetAddedAnalyzerReferences().Any() || 435projectChanges.GetRemovedMetadataReferences().Any() || 436projectChanges.GetRemovedProjectReferences().Any() || 437projectChanges.GetRemovedAnalyzerReferences().Any() ||
ExtractInterface\AbstractExtractInterfaceService.cs (1)
104if (!extractableMembers.Any())
FullyQualify\AbstractFullyQualifyService.cs (1)
279if (types.Any())
IntroduceVariable\AbstractIntroduceVariableService.State.cs (1)
130if (enclosingBlocks.Any())
Organizing\AbstractOrganizingService.cs (1)
39where !o.SyntaxNodeTypes.Any() ||
PullMemberUp\MembersPuller.cs (1)
511return overrideMembersSet.Intersect(destination.GetMembers(), SymbolEquivalenceComparer.Instance).Any();
Shared\Utilities\ExtractTypeHelpers.cs (1)
176while (typesToVisit.Any())
SignatureHelp\SignatureHelpItem.cs (1)
49if (isVariadic && !parameters.Any())
Snippets\SnippetFunctionService.cs (1)
65if (!enumFields.Any())
src\Analyzers\Core\Analyzers\MatchFolderAndNamespace\AbstractMatchFolderAndNamespaceDiagnosticAnalyzer.cs (2)
98if (namespaceDeclaration.Ancestors().OfType<TNamespaceSyntax>().Any()) 106.OfType<TNamespaceSyntax>().Any();
src\Analyzers\Core\CodeFixes\DocumentationComments\AbstractAddDocCommentNodesCodeFixProvider.cs (2)
84if (index != 0 || (!paramNodes.Any() && summaryNode != null)) 133if (!nodes.Any())
src\Analyzers\Core\CodeFixes\GenerateParameterizedMember\TypeParameterSubstitution.cs (1)
118if (similarTypes.Any())
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.State.cs (1)
146if (existingMembers.Any())
Microsoft.CodeAnalysis.LanguageServer (2)
HostWorkspace\ProjectTelemetry\ProjectLoadTelemetryReporter.cs (1)
45if (!projectFileInfos.Any())
LanguageServer\Handler\Restore\RestoreHandler.cs (1)
88if (request.ProjectFilePaths.Any())
Microsoft.CodeAnalysis.LanguageServer.Protocol (26)
Features\CodeCleanup\AbstractCodeCleanupService.cs (13)
252solutionChanges.GetAddedProjects().Any() || 253solutionChanges.GetRemovedProjects().Any() || 254solutionChanges.GetAddedAnalyzerReferences().Any() || 255solutionChanges.GetRemovedAnalyzerReferences().Any() || 257projectChanges => projectChanges.GetAddedProjectReferences().Any() || 258projectChanges.GetRemovedProjectReferences().Any() || 259projectChanges.GetAddedMetadataReferences().Any() || 260projectChanges.GetRemovedMetadataReferences().Any() || 261projectChanges.GetAddedAnalyzerReferences().Any() || 262projectChanges.GetRemovedAnalyzerReferences().Any() || 263projectChanges.GetAddedDocuments().Any() || 264projectChanges.GetAddedAdditionalDocuments().Any() || 265projectChanges.GetAddedAnalyzerConfigDocuments().Any() ||
Features\CodeFixes\CodeFixService.cs (1)
447var hasAnyProjectFixer = projectFixersMap.Any();
Handler\CodeActions\CodeActionResolveHelper.cs (12)
78if (projectChange.GetAddedProjectReferences().Any() 79|| projectChange.GetRemovedProjectReferences().Any() 80|| projectChange.GetAddedMetadataReferences().Any() 81|| projectChange.GetRemovedMetadataReferences().Any() 82|| projectChange.GetAddedAnalyzerReferences().Any() 83|| projectChange.GetRemovedAnalyzerReferences().Any()) 89if (projectChange.GetRemovedDocuments().Any() 90|| projectChange.GetRemovedAdditionalDocuments().Any() 91|| projectChange.GetRemovedAnalyzerConfigDocuments().Any()) 100if (projectChange.GetAddedDocuments().Any() 101|| projectChange.GetAddedAdditionalDocuments().Any() 102|| projectChange.GetAddedAnalyzerConfigDocuments().Any())
Microsoft.CodeAnalysis.Rebuild (1)
CompilationOptionsReader.cs (1)
434if (blobs.Any())
Microsoft.CodeAnalysis.Scripting (1)
Hosting\CommonMemberFilter.cs (1)
68info.GetCustomAttributes<DebuggerHiddenAttribute>()?.Any() == true)
Microsoft.CodeAnalysis.Test.Utilities (11)
Compilation\OperationTreeVerifier.cs (1)
604if (!locals.Any())
Diagnostics\DiagnosticDescription.cs (3)
489var isCSharpOrRazor = actual.Any() && actual.First() is CSDiagnostic or { Descriptor.Category: "Razor" }; 492var includeDefaultSeverity = expected.Any() && expected.All(d => d.DefaultSeverity != null); 493var includeEffectiveSeverity = expected.Any() && expected.All(d => d.EffectiveSeverity != null);
Diagnostics\DiagnosticExtensions.cs (2)
73var includeDefaultSeverity = expected.Any() && expected.All(e => e.DefaultSeverity != null); 74var includeEffectiveSeverity = expected.Any() && expected.All(e => e.EffectiveSeverity != null);
Diagnostics\TrackingDiagnosticAnalyzer.cs (1)
173var missingElements = expectedSubset.GroupJoin(actualSuperset, e => e, a => a, (e, a) => new { Element = e, IsMissing = !a.Any() })
SourceGeneration\TestGenerators.cs (1)
33hintName ??= "generatedFile" + (_sources.Any() ? (_sources.Count + 1).ToString() : "");
Syntax\XmlHelpers.cs (3)
142if (syntaxTree.GetDiagnostics(node).Any()) 188if (syntaxTree.GetDiagnostics(token).Any()) 240if (syntaxTree.GetDiagnostics(trivia).Any())
Microsoft.CodeAnalysis.UnitTests (2)
Collections\HashSet\ISet_Generic_Tests`1.cs (1)
146if (set.Count == 0 || !Enumerable.Any(enumerable))
MetadataReferences\MetadataHelpersTests.cs (1)
451Assert.False(nestedNamespaces.GroupBy(pair => pair.Key).Where(g => g.Count() > 1).Any());
Microsoft.CodeAnalysis.Workspaces (58)
CodeActions\Operations\ApplyChangesOperation.cs (16)
81if (solutionChanges.GetAddedProjects().Any() || 82solutionChanges.GetAddedAnalyzerReferences().Any() || 83solutionChanges.GetRemovedProjects().Any() || 84solutionChanges.GetRemovedAnalyzerReferences().Any()) 97if (changedProject.GetAddedAdditionalDocuments().Any() || 98changedProject.GetAddedAnalyzerConfigDocuments().Any() || 99changedProject.GetAddedAnalyzerReferences().Any() || 100changedProject.GetAddedDocuments().Any() || 101changedProject.GetAddedMetadataReferences().Any() || 102changedProject.GetAddedProjectReferences().Any() || 103changedProject.GetRemovedAdditionalDocuments().Any() || 104changedProject.GetRemovedAnalyzerConfigDocuments().Any() || 105changedProject.GetRemovedAnalyzerReferences().Any() || 106changedProject.GetRemovedDocuments().Any() || 107changedProject.GetRemovedMetadataReferences().Any() || 108changedProject.GetRemovedProjectReferences().Any())
CodeCleanup\AbstractCodeCleanerService.cs (2)
164var hasMultiplePreviousToken = previousTokens.Skip(1).Any(); 165var hasMultipleNextToken = nextTokens.Skip(1).Any();
LinkedFileDiffMerging\AbstractLinkedFileMergeConflictCommentAdditionService.cs (1)
59if (currentPartition.Any())
Rename\SymbolicRenameLocations.cs (1)
86var renameMethodGroupReferences = options.RenameOverloads || !RenameUtilities.GetOverloadedSymbols(symbol).Any();
Rename\SymbolicRenameLocations.ReferenceProcessing.cs (2)
374if (renameStringsAndPositions.Any()) 392if (renameStringsAndPositions.Any())
Shared\Extensions\IFindReferencesResultExtensions.cs (1)
37if (referencedSymbol.Locations.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\INamedTypeSymbolExtensions.cs (1)
340if (!interfacesOrAbstractClasses.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SyntaxNodeExtensions.cs (2)
100return node.GetAncestors<TNode>().Any(); 299Contract.ThrowIfFalse(nodes.Any());
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
397if (!words.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\AnnotationTable.cs (4)
148=> this.GetAnnotations(node).OfType<TSpecificAnnotation>().Any(); 151=> this.GetAnnotations(token).OfType<TSpecificAnnotation>().Any(); 154=> this.GetAnnotations(trivia).OfType<TSpecificAnnotation>().Any(); 157=> this.GetAnnotations(nodeOrToken).OfType<TSpecificAnnotation>().Any();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\ProjectExtensions.cs (1)
56if (project.AnalyzerConfigDocuments.Any())
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\SyntaxEditorExtensions.cs (1)
166var nodesToVerify = nodesBySemanticBoundary.Where(group => group.Skip(1).Any()).Flatten().ToSet();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\SyntaxGeneratorExtensions_CreateEqualsMethod.cs (1)
453return existingMethods.Any();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Simplification\AbstractSimplificationService.cs (2)
145if (reducedNodesMap.Any() || reducedTokensMap.Any())
Workspace\Workspace.cs (22)
1622if (!CanApplyChange(ApplyChangesKind.RemoveProject) && solutionChanges.GetRemovedProjects().Any()) 1627if (!CanApplyChange(ApplyChangesKind.AddProject) && solutionChanges.GetAddedProjects().Any()) 1632if (!CanApplyChange(ApplyChangesKind.AddSolutionAnalyzerReference) && solutionChanges.GetAddedAnalyzerReferences().Any()) 1637if (!CanApplyChange(ApplyChangesKind.RemoveSolutionAnalyzerReference) && solutionChanges.GetRemovedAnalyzerReferences().Any()) 1691if (!CanApplyChange(ApplyChangesKind.AddDocument) && projectChanges.GetAddedDocuments().Any()) 1696if (!CanApplyChange(ApplyChangesKind.RemoveDocument) && projectChanges.GetRemovedDocuments().Any()) 1726if (!CanApplyChange(ApplyChangesKind.AddAdditionalDocument) && projectChanges.GetAddedAdditionalDocuments().Any()) 1731if (!CanApplyChange(ApplyChangesKind.RemoveAdditionalDocument) && projectChanges.GetRemovedAdditionalDocuments().Any()) 1736if (!CanApplyChange(ApplyChangesKind.ChangeAdditionalDocument) && projectChanges.GetChangedAdditionalDocuments().Any()) 1741if (!CanApplyChange(ApplyChangesKind.AddAnalyzerConfigDocument) && projectChanges.GetAddedAnalyzerConfigDocuments().Any()) 1746if (!CanApplyChange(ApplyChangesKind.RemoveAnalyzerConfigDocument) && projectChanges.GetRemovedAnalyzerConfigDocuments().Any()) 1751if (!CanApplyChange(ApplyChangesKind.ChangeAnalyzerConfigDocument) && projectChanges.GetChangedAnalyzerConfigDocuments().Any()) 1756if (!CanApplyChange(ApplyChangesKind.AddProjectReference) && projectChanges.GetAddedProjectReferences().Any()) 1761if (!CanApplyChange(ApplyChangesKind.RemoveProjectReference) && projectChanges.GetRemovedProjectReferences().Any()) 1766if (!CanApplyChange(ApplyChangesKind.AddMetadataReference) && projectChanges.GetAddedMetadataReferences().Any()) 1771if (!CanApplyChange(ApplyChangesKind.RemoveMetadataReference) && projectChanges.GetRemovedMetadataReferences().Any()) 1776if (!CanApplyChange(ApplyChangesKind.AddAnalyzerReference) && projectChanges.GetAddedAnalyzerReferences().Any()) 1781if (!CanApplyChange(ApplyChangesKind.RemoveAnalyzerReference) && projectChanges.GetRemovedAnalyzerReferences().Any()) 1990Contract.ThrowIfTrue(changes.GetAddedProjects().Any()); 1991Contract.ThrowIfTrue(changes.GetRemovedProjects().Any()); 1992Contract.ThrowIfTrue(changes.GetProjectChanges().Any()); 2291if (solution.ProjectIds.Any())
Microsoft.CodeAnalysis.Workspaces.MSBuild (12)
MSBuild\BuildHostProcessManager.cs (4)
326if (document.Root.Elements("Import").Attributes("Sdk").Any()) 330if (document.Root.Elements("Sdk").Any()) 335if (propertyGroups.Elements("TargetFramework").Any() || propertyGroups.Elements("TargetFrameworks").Any())
MSBuild\MSBuildWorkspace.cs (8)
286return changes.GetAddedDocuments().Any() || 287changes.GetRemovedDocuments().Any() || 288changes.GetAddedMetadataReferences().Any() || 289changes.GetRemovedMetadataReferences().Any() || 290changes.GetAddedProjectReferences().Any() || 291changes.GetRemovedProjectReferences().Any() || 292changes.GetAddedAnalyzerReferences().Any() || 293changes.GetRemovedAnalyzerReferences().Any();
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (1)
SolutionGeneration.cs (1)
281if (ProjectReferences != null && ProjectReferences.Any())
Microsoft.CodeAnalysis.Workspaces.UnitTests (6)
Remote\ServiceDescriptorTests.cs (2)
102if (field.GetCustomAttributes<DataMemberAttribute>().Any()) 110if (property.GetCustomAttributes<DataMemberAttribute>().Any())
SolutionTests\SolutionTests.cs (3)
2532Assert.True(solution.ProjectIds.Any(), "Solution was expected to have projects"); 3061Assert.True(sol.ProjectIds.Any(), "Solution was expected to have projects"); 3067Assert.False(sol2.ProjectIds.Any());
SolutionTests\SolutionWithSourceGeneratorTests.cs (1)
845onExecute: context => noTreesPassed = context.Compilation.SyntaxTrees.Any()));
Microsoft.Data.Analysis (1)
DataFrame.Join.cs (1)
266if (crossing.Any())
Microsoft.DotNet.AsmDiff (12)
AssemblySet.cs (3)
111if (string.IsNullOrEmpty(name) && assemblyArray.Length == 0 && allPaths.Any()) 147if (assembliesSnapshot.Any() && loadedAssembliesSet.Any())
Csv\DiffObsoletionCsvColumn.cs (1)
30select a).Any();
DiffCciFilter.cs (3)
93select a).Any(); 122return typeDefinition.Attributes.Where(a => TypeHelper.TypesAreEquivalent(a.Type, generatedAttribute)).Any(); 128return typeDefinitionMember.Attributes.Where(a => TypeHelper.TypesAreEquivalent(a.Type, generatedAttribute)).Any();
DiffCSharpWriter.cs (3)
108if (!attributes.Any() && !properties.Any()) 235if (commentSet.Any() && reviewCommentWriter != null)
DiffEngine.cs (1)
272return tokens.Where(t => t.HasStyle(diffStyle)).Any();
MarkdownDiffExporter.cs (1)
123bool hasChildren = api.Children.Any();
Microsoft.DotNet.Build.Tasks.Feed (6)
src\BlobFeedAction.cs (1)
62if (taskItems.Any())
src\common\LatestLinksManager.cs (1)
53if (!feedConfig.LatestLinkShortUrlPrefixes.Any())
src\PublishArtifactsInManifestBase.cs (2)
1284if (!packagesToPublish.Any()) 1477feedConfig.LatestLinkShortUrlPrefixes.Any())
src\PublishArtifactsInManifestV3.cs (2)
139if (!targetChannelConfig.AkaMSChannelNames.Any()) 164if (!targetFeedConfigs.Any())
Microsoft.DotNet.Build.Tasks.Packaging (14)
CreateTrimDependencyGroups.cs (1)
174return runtimeAssets.Any();
GeneratePackageReport.cs (1)
342if (packageItems.Any() && packageItems.ContainsKey(PackageId))
GetApplicableAssetsFromPackages.cs (2)
99if (compileAssets.Any()) 123if (runtimeAssets.Any())
GetLastStablePackage.cs (1)
151if (candidateVersions.Any())
GetPackageVersion.cs (1)
39if (versionsToConsider.Any())
NuGetAssetResolver.cs (1)
123if (items != null && items.Any())
NuGetPack.cs (1)
274path => PathResolver.GetMatches(builder.Files, file => file.Path, new[] { path }).Any());
UpdatePackageIndex.cs (3)
95if (PackageIds != null && PackageIds.Any()) 110if (nupkgs.Any()) 310if (orphanedAssemblyVersions.Any())
ValidatePackage.cs (3)
350if (matchingFxAssets.Any()) 415if (orphanedAssemblyVersions.Any()) 439if (missingModuleNames.Any())
Microsoft.DotNet.Build.Tasks.VisualStudio (4)
OptProf\GetRunSettingsSessionConfiguration.cs (4)
124var productContainers = config.Products?.Any() == true 128var assemblyContainers = config.Assemblies?.Any() == true 142var productTests = config.Products?.Any() == true 146var assemblyTests = config.Assemblies?.Any() == true
Microsoft.DotNet.Build.Tasks.Workloads (2)
Msi\WorkloadManifestMsi.wix.cs (1)
75if (WorkloadPackGroups.Any())
WorkloadPackageBase.cs (1)
254if (exclusionPatterns.Any())
Microsoft.DotNet.CodeAnalysis (1)
Analyzers\MembersMustExistAnalyzer.cs (1)
50if (!additionalAnalyzerFiles.Any())
Microsoft.DotNet.Deployment.Tasks.Links (3)
Microsoft.DotNet.GenAPI (1)
GenAPITask.cs (1)
192if (!assemblies.Any())
Microsoft.DotNet.Git.IssueManager (1)
Clients\GitHubClient.cs (1)
31if (!commitInfo.Parents.Any()) break;
Microsoft.DotNet.Helix.Sdk (1)
ProvisioningProfileProvider.cs (1)
152if (!rootLevelAppBundles.Any())
Microsoft.DotNet.MacOsPkg (1)
Package.cs (1)
95if (Directory.GetFiles(srcPath, "*.pkg", SearchOption.TopDirectoryOnly).Any())
Microsoft.DotNet.PackageTesting (1)
Package.cs (1)
29IEnumerable<ContentItem> CompileAssets = RefAssets.Any() ? RefAssets : LibAssets;
Microsoft.DotNet.RemoteExecutor (2)
RemoteExecutor.cs (2)
484if (options.RuntimeConfigurationOptions?.Any() == true&& !isNetCore) 519if (options.RuntimeConfigurationOptions?.Any() != true)
Microsoft.DotNet.SharedFramework.Sdk (1)
src\ValidateFileVersions.cs (1)
82if (versionlessFiles.Any())
Microsoft.DotNet.SignTool (5)
src\Configuration.cs (3)
169if (_errors.Any()) 339hasSignInfo = signInfos.Where(s => s.CollisionPriorityId == collisionPriorityId).Any(); 472d.GetMetadata(SignToolConstants.CollisionPriorityId) == _hashToCollisionIdMap[signedFileContentKey])).Any();
src\SignTool.cs (2)
62if (nonOSXFilesToSign.Any()) 71if (osxFilesToSign.Any())
Microsoft.DotNet.SourceBuild.Tasks (8)
src\UsageReport\UsageData.cs (4)
23ProjectDirectories?.Any() != true ? null : new XElement( 27NeverRestoredTarballPrebuilts?.Any() != true ? null : new XElement( 32IgnorePatterns?.Any() != true ? null : new XElement( 36Usages?.Any() != true ? null : new XElement(
src\UsageReport\ValidateUsageAgainstBaseline.cs (3)
87if (diff.Added.Any()) 104if (diff.Removed.Any()) 114if (diff.Unchanged.Any())
src\UsageReport\WritePackageUsageData.cs (1)
93if (projectDirectoriesOutsideRoot.Any())
Microsoft.DotNet.SwaggerGenerator.CmdLine (1)
Program.cs (1)
86if (diagnostic.Errors.Any())
Microsoft.DotNet.SwaggerGenerator.CodeGenerator (1)
Modeler\ServiceClientModelFactory.cs (1)
300if (enumeration.Any())
Microsoft.DotNet.SwaggerGenerator.MSBuild (1)
GenerateSwaggerCode.cs (1)
61if (diagnostic.Errors.Any())
Microsoft.DotNet.VersionTools (10)
Automation\DependencyUpdateResults.cs (1)
43bool hasUsedBuildInfo = UsedInfos.Any();
Automation\PullRequestCreator.cs (1)
202if (statuses.Any())
BuildManifest\Model\SigningInformationModel.cs (5)
62public bool IsEmpty() => !FileExtensionSignInfo.Any() && !FileSignInfo.Any() 63&& !ItemsToSign.Any() && !StrongNameSignInfo.Any() && !CertificatesSignInfo.Any();
BuildManifest\Model\XElementParsingExtensions.cs (1)
46if (missing?.Any() == true)
BuildManifest\VersionIdentifier.cs (1)
202if (!majorMinorPatchDictionary.Any())
Dependencies\BuildOutput\ProjectJsonUpdater.cs (1)
47if (update != null && dependencyChanges.Any())
Microsoft.DotNet.VersionTools.Tasks (2)
BaseDependenciesTask.cs (1)
90if (ProjectJsonFiles != null && ProjectJsonFiles.Any())
VerifyDependencies.cs (1)
21if (updateTasks.Any())
Microsoft.DotNet.XliffTasks (1)
Model\XlfDocument.cs (1)
101if (groupElement != null && !groupElement.Elements().Any())
Microsoft.DotNet.XUnitAssert.Tests (6)
EqualityAssertsTests.cs (4)
1110 return !values.Except(other.values).Any() && !other.values.Except(values).Any(); 3339 return !values.Except(other.values).Any() && !other.values.Except(values).Any();
MemoryAssertsTests.cs (1)
410 (data.Any() ? " ↓ (pos 0)" + Environment.NewLine : "") +
SpanAssertsTests.cs (1)
410 (data.Any() ? " ↓ (pos 0)" + Environment.NewLine : "") +
Microsoft.Extensions.Configuration.Abstractions (1)
ConfigurationExtensions.cs (1)
85return section.Value != null || section.GetChildren().Any();
Microsoft.Extensions.Configuration.Binder (1)
ConfigurationBinder.cs (1)
355if (config.GetChildren().Any())
Microsoft.Extensions.Configuration.KeyPerFile.Tests (1)
KeyPerFileTests.cs (1)
495public bool Exists => _list.Any();
Microsoft.Extensions.DependencyModel (4)
DependencyContextWriter.cs (4)
33if (context.RuntimeGraph.Any()) 77if (compilationOptions.Defines?.Any() == true) 178if (!compilationAssemblies.Any()) 188if (group == null || !group.RuntimeFiles.Any())
Microsoft.Extensions.Diagnostics (1)
Metrics\Configuration\MetricsConfigureOptions.cs (1)
74if (meterSection.GetChildren().Any())
Microsoft.Extensions.FileProviders.Embedded (1)
Manifest\ManifestParser.cs (1)
139if (!element.Elements().Any() &&
Microsoft.Extensions.FileSystemGlobbing (1)
PatternMatchingResult.cs (1)
20: this(files, hasMatches: files.Any())
Microsoft.Extensions.Http.Resilience (2)
Hedging\StandardHedgingHandlerBuilderExtensions.cs (1)
33if (!section.GetChildren().Any())
Resilience\HttpStandardResiliencePipelineBuilderExtensions.cs (1)
30if (!section.GetChildren().Any())
Microsoft.Extensions.Identity.Core (1)
UserManager.cs (1)
2346if (result.Errors.Any())
Microsoft.Extensions.ObjectPool.Microbenchmark (1)
src\Shared\BenchmarkRunner\Program.cs (1)
53if (!report.AllMeasurements.Any())
Microsoft.Extensions.Options.SourceGeneration (2)
Parser.cs (2)
373if (transValidatorType.Constructors.Where(c => !c.Parameters.Any()).Any()) 436if (enumerationValidatorType.Constructors.Where(c => c.Parameters.Length == 0).Any())
Microsoft.Gen.ContextualOptions.Unit.Tests (1)
EmitterTests.cs (1)
122.Any();
Microsoft.Interop.ComInterfaceGenerator (1)
Analyzers\ConvertComImportToGeneratedComInterfaceAnalyzer.cs (1)
87mayRequireAdditionalWork = diagnostics.Diagnostics.Any();
Microsoft.Interop.LibraryImportGenerator (1)
Analyzers\ConvertToLibraryImportAnalyzer.cs (1)
152mayRequireAdditionalWork = diagnostics.Diagnostics.Any();
Microsoft.Interop.SourceGeneration (1)
ManualTypeMarshallingHelper.cs (1)
32&& !Modes.Except(other.Modes).Any();
Microsoft.ML.AutoML (12)
PipelineSuggesters\PipelineSuggester.cs (2)
209r.Pipeline.Trainer.HyperParamSet.Any() && 214if (!proposedParamSet.Any())
TrainerExtensions\BinaryTrainerExtensions.cs (1)
30if (sweepParams == null || !sweepParams.Any())
TrainerExtensions\TrainerExtensionUtil.cs (2)
164if (sweepParams == null || !sweepParams.Any()) 223if (props == null || !props.Any())
TransformInference\TransformInference.cs (2)
360if (columnsWithMissing.Any()) 456if (!concatColNames.Any() || (concatColNames.Count == 1 &&
Utils\BestResultUtil.cs (3)
50if (!results.Any()) { return null; } 63if (!results.Any()) { return null; } 76if (!results.Any()) { return null; }
Utils\SplitUtil.cs (2)
36if (!trainDatasets.Any()) 63if (!columnsToDrop.Any())
Microsoft.ML.AutoML.Tests (2)
SplitUtilTests.cs (2)
52Assert.True(splits.trainDatasets.Any()); 71Assert.True(splits.trainDatasets.Any());
Microsoft.ML.Benchmarks.Tests (2)
BenchmarksTest.cs (2)
69Assert.True(summary.Reports.All(r => r.ExecuteResults.Any(er => er.FoundExecutable && er.Results.Any())), 72Assert.True(summary.Reports.All(report => report.AllMeasurements.Any()),
Microsoft.ML.Data (7)
Data\SchemaDefinition.cs (2)
161.Where(x => x.GetCustomAttributes(typeof(CursorChannelAttribute), false).Any()) 167.Where(x => x.GetCustomAttributes(typeof(CursorChannelAttribute), false).Any());
EntryPoints\EntryPointNode.cs (1)
915if (unexpectedFields.Any())
EntryPoints\InputBuilder.cs (1)
79var optional = fieldInfo.GetCustomAttributes(typeof(TlcModule.OptionalInputAttribute), false).Any();
Evaluators\AucAggregator.cs (2)
115Contracts.CheckParam(PosSample.Any(), nameof(PosSample), "AUC is not defined when there is no positive class in the data"); 116Contracts.CheckParam(NegSample.Any(), nameof(NegSample), "AUC is not defined when there is no negative class in the data");
Transforms\ColumnConcatenatingTransformer.cs (1)
163Contracts.CheckParam(inputColumnNames.Any(), nameof(inputColumnNames), "Can not be empty");
Microsoft.ML.EntryPoints (1)
JsonUtils\GraphRunner.cs (1)
48if (missingInputs.Any())
Microsoft.ML.FastTree (1)
Training\TreeLearners\LeastSquaresRegressionTreeLearner.cs (1)
536if (!ParentHistogramArray[flock].IsSplittable.Any() && _parallelTraining.IsSkipNonSplittableHistogram())
Microsoft.ML.GenAI.Mistral (1)
Mistral_7B_0_3ChatTemplateBuilder.cs (1)
65if (tools?.Any() == true)
Microsoft.ML.IntegrationTests (2)
ModelFiles.cs (2)
366Assert.False((loadedWithSchema as TransformerChain<ITransformer>).Any()); 372Assert.False((loadedWithLoader as TransformerChain<ITransformer>).Any());
Microsoft.ML.TimeSeries (2)
RootCauseAnalyzer.cs (2)
820if (x.Keys.Except(y.Keys).Any()) 824if (y.Keys.Except(x.Keys).Any())
Microsoft.ML.Transforms (2)
SvmLight\SvmLightLoader.cs (1)
428return new Cursor(this, columnsNeeded.Any());
Text\TextFeaturizingEstimator.cs (1)
413_host.CheckParam(source.Any(), nameof(source));
Microsoft.VisualStudio.LanguageServices (23)
CallHierarchy\CallHierarchyProvider.cs (1)
120if (overrides.Any())
CallHierarchy\Finders\AbstractCallFinder.cs (1)
173if (initializerLocations.Any())
ChangeSignature\ChangeSignatureDialogViewModel.cs (1)
206if (!AllParameters.Any())
ChangeSignature\ChangeSignatureDialogViewModel.ParameterViewModels.cs (1)
80(ChangeSignatureDialogViewModel._parametersWithDefaultValues.Any() || ChangeSignatureDialogViewModel._paramsParameter != null))
GenerateType\GenerateTypeDialogViewModel.cs (2)
376if (this.SelectedProject.Documents.Where(n => n != null).Where(n => n.FilePath == FullFilePath).Any() || 378this.SelectedProject.Documents.Where(n => n.Name != null && n.Folders.Count > 0 && n.Name == this.FileName && this.Folders.SequenceEqual(n.Folders)).Any()) ||
Implementation\VsRefactorNotifyService.cs (1)
140if (!changedDocumentIDs.Any())
Library\ObjectBrowser\AbstractListItemFactory.cs (2)
589if (!projectIds.Any()) 646if (!compilation.References.Any())
Progression\GraphQueries\ContainsChildrenGraphQuery.cs (2)
30var containsChildren = SymbolContainment.GetContainedSymbols(symbol).Any(); 41node, DgmlNodeProperties.ContainsChildren, childNodes.Any(), cancellationToken);
ProjectSystem\Extensions\ProjectExtensions.cs (1)
20Debug.Assert(containers.Any());
ProjectSystem\VisualStudioWorkspaceImpl.cs (1)
788else if (folders.Any())
PullMemberUp\MainDialog\BaseTypeTreeNodeViewModel.cs (1)
52while (queue.Any())
Snippets\SnippetExpansionClient.cs (3)
646if (declarations.Any()) 662if (!declarations.Any()) 1107if (failedReferenceAdditions.Any())
SyncNamespaces\SyncNamespacesCommandHandler.cs (1)
146if (_workspace.CurrentSolution.GetChanges(solution).GetProjectChanges().Any())
TableDataSource\Suppression\VisualStudioSuppressionFixService.cs (2)
544if (documentDiagnosticsToFix.Any()) 608if (projectDiagnosticsToFix.Any())
ValueTracking\TreeViewItemBase.cs (1)
51if (IsNodeExpanded && ChildItems.Any())
Venus\ContainedDocument.cs (2)
264if (editorVisibleSpansInOriginal.Count == 0 || !changes.Any()) 758if (!visibleSpanIndex.Any())
Microsoft.VisualStudio.LanguageServices.CSharp (1)
Snippets\CSharpSnippetExpansionLanguageHelper.cs (1)
90if (!newUsingDirectives.Any())
Microsoft.VisualStudio.LanguageServices.CSharp.UnitTests (2)
Interactive\Commands\ResetInteractiveTests.cs (2)
119if (expectedReferences.Any()) 124if (expectedUsings.Any())
Microsoft.VisualStudio.LanguageServices.Xaml (2)
Implementation\LanguageServer\Extensions\SymbolExtensions.cs (1)
59if (builder.Any())
Implementation\LanguageServer\Handler\Hover\HoverHandler.cs (1)
72if (descriptionBuilder.Any())
MSBuild (3)
ReflectableTaskPropertyInfo.cs (2)
49propertyInfo.GetCustomAttributes(typeof(OutputAttribute), true).Any(), 50propertyInfo.GetCustomAttributes(typeof(RequiredAttribute), true).Any())
TerminalLogger\TerminalLogger.cs (1)
415if (_testRunSummaries.Any())
Roslyn.VisualStudio.DiagnosticsWindow (1)
PerfMargin\PerfMarginPanel.cs (1)
147if (selectedItem.Tag is ActivityLevel context && context.Children != null && context.Children.Any())
RunTests (1)
AssemblyScheduler.cs (1)
242if (currentFilters.Any())
Sockets.BindTests (1)
src\Servers\Kestrel\test\BindTests\AddressRegistrationTests.cs (1)
295if (errors.Any())
Swaggatherer (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
System.Collections.Immutable (3)
System\Collections\Frozen\EmptyFrozenSet.cs (1)
46!other.Any();
System\Collections\Immutable\ImmutableHashSet_1.cs (1)
872return other.Any();
System\Collections\Immutable\ImmutableSortedSet_1.cs (1)
409return other.Any();
System.ComponentModel.Annotations (1)
System\ComponentModel\DataAnnotations\Validator.cs (1)
527if (_store.GetPropertyValidationAttributes(context).Any())
System.ComponentModel.Composition (13)
Microsoft\Internal\Collections\CollectionServices.cs (2)
68if (second == null || !second.Any()) 73if (source == null || !source.Any())
System\ComponentModel\Composition\AttributedModel\AttributedPartCreationInfo.cs (2)
118return GetExportMembers(_type).Any() || 119GetInheritedExports(_type).Any();
System\ComponentModel\Composition\CompositionResult.cs (1)
28get { return _errors == null || !_errors.Any(); }
System\ComponentModel\Composition\CompositionResultOfT.cs (1)
39get { return _errors == null || !_errors.Any(); }
System\ComponentModel\Composition\Hosting\AggregateExportProvider.cs (1)
182bool anyExports = exports.Any();
System\ComponentModel\Composition\Hosting\FilteredCatalog.cs (2)
221if (result.AddedDefinitions.Any() || result.RemovedDefinitions.Any())
System\ComponentModel\Composition\Primitives\ContractBasedImportDefinition.cs (1)
371if (_requiredMetadata.Any())
System\ComponentModel\Composition\ReflectionModel\LazyMemberInfo.cs (2)
176if (accessors.Where(accessor => (accessor != null) && (accessor.MemberType != MemberTypes.Method)).Any()) 191if (accessors.Where(accessor => (accessor != null) && (accessor.MemberType != MemberTypes.Method)).Any())
System\ComponentModel\Composition\ReflectionModel\ReflectionComposablePart.cs (1)
344if (ImportDefinitions.Any())
System.Composition.TypedParts (1)
System\Composition\TypedParts\TypedPartExportDescriptorProvider.cs (1)
67if (!forKey.Any(x => x.Metadata.Any()))
System.Data.Odbc (3)
Common\System\Data\Common\DBConnectionString.cs (3)
309Debug.Assert(!combinedSet._restrictionValues.Except(componentSet._restrictionValues).Any(), "Combined set allows values not allowed by component set"); 328Debug.Assert(!combinedSet._restrictionValues.Intersect(componentSet._restrictionValues).Any(), "Combined values allows values prevented by component set"); 335Debug.Assert(!componentSet._restrictionValues.Except(combinedSet._restrictionValues).Any(), "Combined values does not prevent all of the values prevented by the component set");
System.Private.CoreLib.Generators (1)
IntrinsicsInSystemPrivateCoreLibAnalyzer.cs (1)
478if (GetCompExactlyDependsOnUseList(symbol, onLoadData).Any())
System.Windows.Forms (4)
System\Windows\Forms\Dialogs\TaskDialog\TaskDialog.cs (4)
1396if (customButtonElements.Any()) 1414if (radioButtonElements.Any()) 1472if (customButtonElements.Any()) 1497if (radioButtonElements.Any())
Templates.Blazor.Tests (8)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
Templates.Blazor.WebAssembly.Auth.Tests (8)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
Templates.Blazor.WebAssembly.Tests (8)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
Templates.Mvc.Tests (8)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
Templates.Tests (8)
src\Shared\CertificateGeneration\CertificateManager.cs (2)
213if (certificates.Any()) 407if (certificates.Any())
src\Shared\CertificateGeneration\UnixCertificateManager.cs (1)
647if (!profiles.Any())
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
Wasm.Performance.ConsoleHost (5)
src\Shared\CommandLineUtils\CommandLine\CommandLineApplication.cs (3)
474if (arguments.Any()) 490if (options.Any()) 506if (commands.Any())
src\Shared\CommandLineUtils\CommandLine\CommandOption.cs (2)
73if (Values.Any()) 95return Values.Any();
XmlFileLogger (3)
LogProcessNode.cs (1)
160if (GetChildrenOfType<T>().Any())
ObjectModel\Item.cs (1)
74if (Metadata.Any() || !collapseSingleItem)
ObjectModel\TaskParameter.cs (1)
49if (collapseSingleItem && items.Count == 1 && !items[0].Metadata.Any())
xunit.assert (2)
Sdk\AssertHelper.cs (2)
157 && !p.GetCustomAttributes(typeof(ObsoleteAttribute)).Any() 158 && !p.GetMethod.GetCustomAttributes(typeof(ObsoleteAttribute)).Any()
xunit.console (2)
common\AssemblyResolution\Microsoft.Extensions.DependencyModel\DependencyContextJsonReader.cs (2)
398if (groupRuntimeAssemblies.Any()) 410if (groupNativeLibraries.Any())