Skip to content

Commit a771b2b

Browse files
committed
Added a couple of traces
1 parent 6e974f1 commit a771b2b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

SourceGeneratorContext/Generator.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ public void Initialize(IncrementalGeneratorInitializationContext context)
1212

1313
context.RegisterPostInitializationOutput(static postInitializationContext =>
1414
{
15+
LightweightTrace.Add(GeneratorStage.RegisterPostInitializationOutput);
16+
1517
postInitializationContext.AddSource(
1618
Templates.IncludeFlagsHintName,
1719
Templates.IncludeFlags);
@@ -79,6 +81,8 @@ private void Action(SourceProductionContext sourceProductionContext, SourceBuild
7981

8082
var hintName = attributeContext.CreateHintName("SourceGeneratorContext");
8183
var generatedSource = codeGenerator.GetSourceText();
84+
85+
LightweightTrace.Add(GeneratorStage.SourceProductionContextAddSource);
8286
sourceProductionContext.AddSource(hintName, generatedSource);
8387
}
8488
}

0 commit comments

Comments
 (0)