3 writes to GeneralDiagnosticOption
Microsoft.CodeAnalysis (1)
Compilation\CompilationOptions.cs (1)
307this.GeneralDiagnosticOption = generalDiagnosticOption;
Microsoft.CodeAnalysis.CSharp (1)
CSharpCompilationOptions.cs (1)
461return new CSharpCompilationOptions(this) { GeneralDiagnosticOption = value };
Microsoft.CodeAnalysis.VisualBasic (1)
VisualBasicCompilationOptions.vb (1)
846Return New VisualBasicCompilationOptions(Me) With {.GeneralDiagnosticOption = value}
80 references to GeneralDiagnosticOption
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation.Test (1)
CSharpCompilerTest.cs (1)
96Assert.Equal(ReportDiagnostic.Default, compilationOptions.GeneralDiagnosticOption);
Microsoft.CodeAnalysis (10)
Compilation\CompilationOptions.cs (3)
632this.GeneralDiagnosticOption == other.GeneralDiagnosticOption && 679Hash.Combine((int)this.GeneralDiagnosticOption,
Compilation\DeterministicKeyBuilder.cs (1)
453writer.Write("generalDiagnosticOption", options.GeneralDiagnosticOption);
DiagnosticAnalyzer\AnalyzerDriver.cs (2)
964compilation.Options.GeneralDiagnosticOption == ReportDiagnostic.Error) 987compilation.Options.GeneralDiagnosticOption == ReportDiagnostic.Error)
DiagnosticAnalyzer\AnalyzerOptionsExtensions.cs (2)
70if (severity == ReportDiagnostic.Warn && compilation.Options.GeneralDiagnosticOption == ReportDiagnostic.Error) 82if (severity == ReportDiagnostic.Warn && compilation.Options.GeneralDiagnosticOption == ReportDiagnostic.Error)
DiagnosticAnalyzer\CompilationWithAnalyzers.cs (2)
1153/// 2) <see cref="CompilationOptions.GeneralDiagnosticOption"/> specified for the given <paramref name="compilation"/>. 1163/// 2) <see cref="CompilationOptions.GeneralDiagnosticOption"/> specified for the given <paramref name="compilation"/>.
Microsoft.CodeAnalysis.CSharp (4)
CSharpCompilationOptions.cs (3)
245generalDiagnosticOption: other.GeneralDiagnosticOption, 456if (this.GeneralDiagnosticOption == value) 767GeneralDiagnosticOption,
Errors\MessageProvider.cs (1)
132options.GeneralDiagnosticOption,
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (1)
Diagnostics\DiagnosticAnalyzerTests.cs (1)
1830if (compilation.Options.GeneralDiagnosticOption == ReportDiagnostic.Error)
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (5)
Compilation\CSharpCompilationOptionsTests.cs (5)
84TestHiddenProperty((old, value) => old.WithGeneralDiagnosticOption(value), opt => opt.GeneralDiagnosticOption, ReportDiagnostic.Suppress); 122TestProperty((old, value) => old.WithGeneralDiagnosticOption(value), opt => opt.GeneralDiagnosticOption, ReportDiagnostic.Suppress); 193Assert.Equal(ReportDiagnostic.Default, defaultWarnings.GeneralDiagnosticOption); 196Assert.Equal(ReportDiagnostic.Error, new CSharpCompilationOptions(OutputKind.ConsoleApplication).WithGeneralDiagnosticOption(ReportDiagnostic.Error).GeneralDiagnosticOption); 197Assert.Equal(ReportDiagnostic.Default, new CSharpCompilationOptions(OutputKind.ConsoleApplication).WithGeneralDiagnosticOption(ReportDiagnostic.Default).GeneralDiagnosticOption);
Microsoft.CodeAnalysis.Rebuild.UnitTests (1)
RoundTripUtil.cs (1)
223case nameof(CompilationOptions.GeneralDiagnosticOption):
Microsoft.CodeAnalysis.Test.Utilities (3)
Diagnostics\DiagnosticExtensions.cs (3)
213if (c.Options.GeneralDiagnosticOption == ReportDiagnostic.Default && 234var toggledOption = c.Options.GeneralDiagnosticOption == ReportDiagnostic.Error ? 335/// 2) <see cref="CompilationOptions.GeneralDiagnosticOption"/> specified for the given <paramref name="compilation"/>.
Microsoft.CodeAnalysis.VisualBasic (4)
Errors\MessageProvider.vb (1)
123options.GeneralDiagnosticOption,
VisualBasicCompilationOptions.vb (3)
319generalDiagnosticOption:=other.GeneralDiagnosticOption, 842If value = Me.GeneralDiagnosticOption Then 1136GeneralDiagnosticOption,
Microsoft.CodeAnalysis.VisualBasic.CommandLine.UnitTests (31)
CommandLineTests.vb (31)
288Assert.Equal(cmd.Arguments.CompilationOptions.GeneralDiagnosticOption, ReportDiagnostic.Suppress) 291Assert.Equal(cmd.Arguments.CompilationOptions.GeneralDiagnosticOption, ReportDiagnostic.Error) 294Assert.Equal(cmd.Arguments.CompilationOptions.GeneralDiagnosticOption, ReportDiagnostic.Error) 297Assert.Equal(cmd.Arguments.CompilationOptions.GeneralDiagnosticOption, ReportDiagnostic.Suppress) 300Assert.Equal(cmd.Arguments.CompilationOptions.GeneralDiagnosticOption, ReportDiagnostic.Suppress) 303Assert.Equal(cmd.Arguments.CompilationOptions.GeneralDiagnosticOption, ReportDiagnostic.Suppress) 2848Assert.True(parsedArgs.CompilationOptions.GeneralDiagnosticOption = ReportDiagnostic.Warn) 5801Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5805Assert.Equal(ReportDiagnostic.Error, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5809Assert.Equal(ReportDiagnostic.Error, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5813Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5817Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5822Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5826Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5831Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5835Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5839Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5844Assert.Equal(ReportDiagnostic.Suppress, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5848Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 5852Assert.Equal(ReportDiagnostic.Default, parsedArgs.CompilationOptions.GeneralDiagnosticOption) 8721Assert.Equal(expected:=ReportDiagnostic.Error, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8741Assert.Equal(expected:=ReportDiagnostic.Error, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8762Assert.Equal(expected:=ReportDiagnostic.Error, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8783Assert.Equal(expected:=ReportDiagnostic.Default, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8804Assert.Equal(expected:=ReportDiagnostic.Default, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8825Assert.Equal(expected:=ReportDiagnostic.Error, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8846Assert.Equal(expected:=ReportDiagnostic.Default, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8868Assert.Equal(expected:=ReportDiagnostic.Error, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8889Assert.Equal(expected:=ReportDiagnostic.Suppress, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8912Assert.Equal(expected:=ReportDiagnostic.Suppress, actual:=arguments.CompilationOptions.GeneralDiagnosticOption) 8935Assert.Equal(expected:=ReportDiagnostic.Error, actual:=arguments.CompilationOptions.GeneralDiagnosticOption)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (1)
Diagnostics\DiagnosticAnalyzerTests.vb (1)
1291If compilation.Options.GeneralDiagnosticOption = ReportDiagnostic.Error Then
Microsoft.CodeAnalysis.Workspaces (1)
Serialization\AbstractOptionsSerializationService.cs (1)
48writer.WriteInt32((int)options.GeneralDiagnosticOption);
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (2)
Workspaces\TestWorkspace_XmlCreation.cs (2)
163if (options.GeneralDiagnosticOption != ReportDiagnostic.Default) 165element.SetAttributeValue(ReportDiagnosticAttributeName, options.GeneralDiagnosticOption);
Microsoft.VisualStudio.LanguageServices.CSharp.UnitTests (8)
ProjectSystemShim\CPS\AnalyzersTests.cs (2)
37Assert.Equal(expected: ReportDiagnostic.Default, actual: options.GeneralDiagnosticOption); 44Assert.Equal(expected: ReportDiagnostic.Error, actual: options.GeneralDiagnosticOption);
ProjectSystemShim\LegacyProject\AnalyzersTests.cs (6)
41Assert.Equal(expected: ReportDiagnostic.Default, actual: options.GeneralDiagnosticOption); 47Assert.Equal(expected: ReportDiagnostic.Error, actual: options.GeneralDiagnosticOption); 82Assert.Equal(expected: ReportDiagnostic.Warn, actual: options.GeneralDiagnosticOption); 89Assert.Equal(expected: ReportDiagnostic.Error, actual: options.GeneralDiagnosticOption); 248Assert.Equal(expected: ReportDiagnostic.Error, actual: options.GeneralDiagnosticOption); 259Assert.Equal(expected: ReportDiagnostic.Warn, actual: options.GeneralDiagnosticOption);
Microsoft.VisualStudio.LanguageServices.UnitTests (8)
ProjectSystemShim\ConvertedVisualBasicProjectOptionsTests.vb (8)
27Assert.Equal(expected:=ReportDiagnostic.Error, actual:=convertedOptions.GeneralDiagnosticOption) 40Assert.Equal(expected:=ReportDiagnostic.Error, actual:=convertedOptions.GeneralDiagnosticOption) 54Assert.Equal(expected:=ReportDiagnostic.Error, actual:=convertedOptions.GeneralDiagnosticOption) 71Assert.Equal(expected:=ReportDiagnostic.Error, actual:=convertedOptions.GeneralDiagnosticOption) 88Assert.Equal(expected:=ReportDiagnostic.Error, actual:=convertedOptions.GeneralDiagnosticOption) 105Assert.Equal(expected:=ReportDiagnostic.Error, actual:=convertedOptions.GeneralDiagnosticOption) 124Assert.Equal(expected:=ReportDiagnostic.Suppress, actual:=convertedOptions.GeneralDiagnosticOption) 143Assert.Equal(expected:=ReportDiagnostic.Default, actual:=convertedOptions.GeneralDiagnosticOption)