Skip to content

Commit 795f6df

Browse files
authored
Merge pull request #33 from ByronMayne/32-compiler-error-on-207-in-generated-class
Fixed the compiler error due to using the environment
2 parents 34708c0 + 2b17dde commit 795f6df

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/SourceGenerator.Foundations/Templates/SourceGeneratorHoistBase.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,13 @@ internal abstract class SourceGeneratorHoist
3535
3636
static SourceGeneratorHoist()
3737
{
38+
#pragma warning disable RS1035 // Do not use APIs banned for analyzers
3839
if(bool.TryParse(System.Environment.GetEnvironmentVariable("SGF_DEBUGGER_LAUNCH"), out bool launchDebugger)
3940
&& launchDebugger)
4041
{
4142
System.Diagnostics.Debugger.Launch();
4243
}
44+
#pragma warning restore RS1035 // Do not use APIs banned for analyzers
4345
4446
4547
s_assembliesWithResources = new List<Assembly>();

0 commit comments

Comments
 (0)