86 references to CompilationProvider
Microsoft.AspNetCore.App.SourceGenerators (1)
PublicTopLevelProgramGenerator.cs (1)
20var internalGeneratedProgramClass = context.CompilationProvider
Microsoft.AspNetCore.SignalR.Client.SourceGenerator (2)
HubClientProxyGenerator.cs (1)
26var compilationAndMethodDeclaration = context.CompilationProvider.Combine(methodDeclaration);
HubServerProxyGenerator.cs (1)
26var compilationAndMethodDeclaration = context.CompilationProvider.Combine(methodDeclaration);
Microsoft.CodeAnalysis (3)
SourceGeneration\GeneratorAdaptor.cs (1)
50var contextBuilderSource = context.CompilationProvider
SourceGeneration\Nodes\SyntaxValueProvider_ForAttributeWithMetadataName.cs (1)
90.Combine(_context.CompilationProvider)
SourceGeneration\Nodes\SyntaxValueProvider_ForAttributeWithSimpleName.cs (1)
65var syntaxTreesProvider = _context.CompilationProvider
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (4)
CommandLineTests.cs (4)
10407var syntaxTreeInput = ctx.CompilationProvider.Select((c, _) => c.SyntaxTrees.First()); 10475ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, po) => 10515ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, value) => 10522ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, po) =>
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (53)
SourceGeneration\GeneratorDriverTests.cs (52)
489ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => 500ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => 1473var generator = new IncrementalGeneratorWrapper(new PipelineCallbackGenerator((ctx) => ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => throw e))); 1543var name = ctx.CompilationProvider.Select((c, _) => new ThrowWhenEqualsItem(e)); 1591ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => spc.AddSource("test", "")); 1592ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => throw e); 1620ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => throw e); 1625ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => spc.AddSource("test", "")); 1735ctx.RegisterSourceOutput(ctx.CompilationProvider.Select((c, ct) => c).WithTrackingName("IdentityTransform"), (spc, c) => { }); 1782ctx.RegisterSourceOutput(ctx.CompilationProvider.Select((c, ct) => c).WithTrackingName("CompilationTransform"), (spc, c) => { }); 2000var compilationSource = ctx.CompilationProvider.WithComparer(new LambdaComparer<Compilation>((c1, c2) => true, 0)); 2036var compilationSource = ctx.CompilationProvider.Combine(ctx.AdditionalTextsProvider.Collect()) 2298var source = ctx.CompilationProvider; 2299var source2 = ctx.CompilationProvider.Combine(source); 2300var source3 = ctx.CompilationProvider.Combine(source2); 2301var source4 = ctx.CompilationProvider.Combine(source3); 2302var source5 = ctx.CompilationProvider.Combine(source4); 2596var step1 = ctx.CompilationProvider.Select((c, ct) => { generatorCancelled = true; cts.Cancel(); return c; }); 2689ctx.CompilationProvider.Combine(classDeclarations.Collect()); 3216ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, ct) => context.AddSource("Source", "")); 3217ctx.RegisterImplementationSourceOutput(ctx.CompilationProvider, (context, ct) => context.AddSource("Implementation", "")); 3282ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, ct) => { }); 3416ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, ct) => { }); 3475ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 3519ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 3547ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 3578ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 3587ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 3626ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 3670var nullArray = ctx.CompilationProvider.Select((c, _) => null as object[]); 3745ctx.RegisterSourceOutput(ctx.CompilationProvider, (ctx, _) => 3777ctx.RegisterSourceOutput(ctx.CompilationProvider, (ctx, comp) => 3871ctx.RegisterSourceOutput(ctx.CompilationProvider, (ctx, comp) => 3903ctx.RegisterSourceOutput(ctx.CompilationProvider, (ctx, comp) => 3995ctx.RegisterSourceOutput(ctx.CompilationProvider, (ctx, comp) => 4436var generator1 = new PipelineCallbackGenerator((ctx) => { ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { spc.AddSource("gen1Source.cs", c.SyntaxTrees.First().GetRoot().ToFullString() + " //generator1"); }); }).AsSourceGenerator(); 4437var generator2 = new PipelineCallbackGenerator2((ctx) => { ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { spc.AddSource("gen2Source.cs", c.SyntaxTrees.First().GetRoot().ToFullString() + " //generator2"); }); }).AsSourceGenerator(); 4481var generator1 = new PipelineCallbackGenerator((ctx) => { ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { spc.AddSource("gen1Source.cs", "//" + c.SyntaxTrees.First().GetRoot().ToFullString() + " generator1"); }); }).AsSourceGenerator(); 4482var generator2 = new PipelineCallbackGenerator2((ctx) => { ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { spc.AddSource("gen2Source.cs", "//" + c.SyntaxTrees.First().GetRoot().ToFullString() + " generator2"); }); }).AsSourceGenerator(); 4505var generator1 = new PipelineCallbackGenerator((ctx) => { ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { spc.AddSource("gen1Source.cs", c.SyntaxTrees.First().GetRoot().ToFullString() + " //generator1"); }); }).AsSourceGenerator(); 4506var generator2 = new PipelineCallbackGenerator2((ctx) => { initWasCalled = true; ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { spc.AddSource("gen2Source.cs", c.SyntaxTrees.First().GetRoot().ToFullString() + " //generator2"); }); }).AsSourceGenerator(); 4534var generator1 = new PipelineCallbackGenerator((ctx) => { ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, c) => { stepRan = true; }); }).AsSourceGenerator(); 4564ctx.RegisterSourceOutput(ctx.CompilationProvider, (context, text) => 4647var generator = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("a", "value"); }); }); 4664var generator = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("a", "value"); }); }); 4682var generator = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("a", "value"); hostCtx.AddOutput("b", "value2"); }); }); 4702var generator = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("a", "value"); hostCtx.AddOutput("a", "value2"); }); }); 4719var generator1 = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("gen1", "value1"); }); }); 4720var generator2 = new PipelineCallbackGenerator2((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("gen2", "value2"); }); }); 4737var generator1 = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("gen", "value1"); }); }); 4738var generator2 = new PipelineCallbackGenerator2((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { hostCtx.AddOutput("gen", "value2"); }); }); 4755var generator = new PipelineCallbackGenerator((ctx) => { ctx.RegisterHostOutput(ctx.CompilationProvider, (hostCtx, c) => { throw new InvalidOperationException("failed"); }); });
SourceGeneration\SyntaxAwareGeneratorTests.cs (1)
1945ctx.RegisterSourceOutput(ctx.CompilationProvider, (spc, s) => spc.AddSource("test", ""));
Microsoft.CodeAnalysis.VisualBasic.CommandLine.UnitTests (2)
CommandLineTests.vb (2)
10705ctx.RegisterHostOutput(ctx.CompilationProvider, Sub(hostCtx, value) 10710ctx.RegisterSourceOutput(ctx.CompilationProvider, Sub(spc, po)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (5)
SourceGeneration\GeneratorDriverTests.vb (5)
301ctx.RegisterSourceOutput(ctx.CompilationProvider, 331ctx.RegisterSourceOutput(ctx.CompilationProvider, 423ctx.RegisterSourceOutput(ctx.CompilationProvider, 453ctx.RegisterSourceOutput(ctx.CompilationProvider, 543ctx.RegisterSourceOutput(ctx.CompilationProvider,
Microsoft.Extensions.Options.SourceGeneration (1)
Generator.cs (1)
28context.CompilationProvider.Combine(typeDeclarations.Collect());
Microsoft.Gen.ComplianceReports (1)
src\Generators\Shared\GeneratorUtilities.cs (1)
70var compilationAndTypes = context.CompilationProvider.Combine(declarations.Collect());
Microsoft.Gen.ContextualOptions (2)
ContextualOptionsGenerator.cs (1)
25context.CompilationProvider.Combine(typeDeclarations.Collect());
src\Generators\Shared\GeneratorUtilities.cs (1)
70var compilationAndTypes = context.CompilationProvider.Combine(declarations.Collect());
Microsoft.Gen.Logging (2)
LoggingGenerator.cs (1)
26context.CompilationProvider.Combine(typeDeclarations.Collect());
src\Generators\Shared\GeneratorUtilities.cs (1)
70var compilationAndTypes = context.CompilationProvider.Combine(declarations.Collect());
Microsoft.Gen.Metrics (1)
src\Generators\Shared\GeneratorUtilities.cs (1)
70var compilationAndTypes = context.CompilationProvider.Combine(declarations.Collect());
Microsoft.Gen.MetricsReports (1)
src\Generators\Shared\GeneratorUtilities.cs (1)
70var compilationAndTypes = context.CompilationProvider.Combine(declarations.Collect());
Microsoft.Interop.ComInterfaceGenerator (1)
ComClassGenerator.cs (1)
21var unsafeCodeIsEnabled = context.CompilationProvider.Select((comp, ct) => comp.Options is CSharpCompilationOptions { AllowUnsafe: true }); // Unsafe code enabled
Microsoft.Interop.JavaScript.JSImportGenerator (1)
JSExportGenerator.cs (1)
37var assemblyName = context.CompilationProvider.Select(static (c, _) => c.AssemblyName);
Microsoft.Interop.LibraryImportGenerator (1)
LibraryImportGenerator.cs (1)
72context.CompilationProvider
Microsoft.Interop.SourceGeneration (1)
IncrementalGeneratorInitializationContextExtensions.cs (1)
47return context.CompilationProvider
Microsoft.Maui.Controls.SourceGen (1)
CodeBehindGenerator.cs (1)
57 var referenceCompilationProvider = initContext.CompilationProvider
System.Text.Json.SourceGeneration (1)
JsonSourceGenerator.Roslyn4.0.cs (1)
31IncrementalValueProvider<KnownTypeSymbols> knownTypeSymbols = context.CompilationProvider
System.Windows.Forms.Analyzers.CSharp (1)
System\Windows\Forms\CSharp\Generators\ApplicationConfiguration\ApplicationConfigurationGenerator.cs (1)
74IncrementalValueProvider<OutputKind> outputKindProvider = context.CompilationProvider.Select((compilation, _)
System.Windows.Forms.PrivateSourceGenerators (1)
System\Windows\Forms\SourceGenerators\EnumValidationGenerator.cs (1)
74IncrementalValuesProvider<EnumValidationInfo> enumsToValidate = context.CompilationProvider.Combine(argumentsToValidate.Collect()).SelectMany(