376 references to CSharp8
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation (1)
CSharpCompiler.cs (1)
221parseOptions = parseOptions.WithLanguageVersion(LanguageVersion.CSharp8);
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation.Test (1)
CSharpCompilerTest.cs (1)
125Assert.Equal(LanguageVersion.CSharp8, parseOptions.LanguageVersion);
Microsoft.CodeAnalysis.CodeStyle.UnitTestUtilities (4)
src\Features\DiagnosticsTestUtilities\CodeActions\CSharpCodeFixVerifier`2+Test.cs (2)
60/// <see cref="LanguageVersion.CSharp8"/>. 62public LanguageVersion LanguageVersion { get; set; } = LanguageVersion.CSharp8;
src\Features\DiagnosticsTestUtilities\CodeActions\CSharpCodeRefactoringVerifier`1+Test.cs (2)
59/// <see cref="LanguageVersion.CSharp8"/>. 61public LanguageVersion LanguageVersion { get; set; } = LanguageVersion.CSharp8;
Microsoft.CodeAnalysis.CSharp (5)
Errors\MessageID.cs (1)
596return LanguageVersion.CSharp8;
LanguageVersion.cs (4)
288case LanguageVersion.CSharp8: 325case LanguageVersion.CSharp8: 398case LanguageVersion.CSharp8: 503result = LanguageVersion.CSharp8;
Microsoft.CodeAnalysis.CSharp.CodeStyle (12)
src\Analyzers\CSharp\Analyzers\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionDiagnosticAnalyzer.cs (1)
35if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\MakeLocalFunctionStatic\MakeLocalFunctionStaticHelper.cs (1)
15=> languageVersion >= LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\MakeStructMemberReadOnly\CSharpMakeStructMemberReadOnlyAnalyzer.cs (1)
38if (compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryNullableDirective\CSharpRemoveRedundantNullableDirectiveDiagnosticAnalyzer.cs (1)
37if (compilation.LanguageVersion < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseCompoundAssignment\CSharpUseCompoundAssignmentDiagnosticAnalyzer.cs (1)
27options.LanguageVersion() >= LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\UseCompoundAssignment\CSharpUseCompoundCoalesceAssignmentDiagnosticAnalyzer.cs (1)
46if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseIndexOperatorDiagnosticAnalyzer.cs (1)
64if (compilation.LanguageVersion < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseRangeOperatorDiagnosticAnalyzer.cs (1)
57if (compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseIsNullCheck\CSharpUseIsNullCheckForReferenceEqualsDiagnosticAnalyzer.cs (1)
25=> compilation.LanguageVersion() >= LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpAsAndMemberAccessDiagnosticAnalyzer.cs (1)
46if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UsePatternMatching\UsePatternMatchingHelpers.cs (1)
24requiredLanguageVersion = LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\UseSimpleUsingStatement\UseSimpleUsingStatementDiagnosticAnalyzer.cs (1)
70if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (3)
src\Analyzers\CSharp\CodeFixes\UseLocalFunction\CSharpUseLocalFunctionCodeFixProvider.cs (1)
89if (languageVersion >= LanguageVersion.CSharp8)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSemanticFactsService.cs (2)
46if (semanticModel.Compilation.LanguageVersion().MapSpecifiedToEffectiveVersion() >= LanguageVersion.CSharp8) 68var isLanguageVersionGreaterOrEqualToCSharp8 = (semanticModel.Compilation as CSharpCompilation)?.LanguageVersion >= LanguageVersion.CSharp8;
Microsoft.CodeAnalysis.CSharp.CodeStyle.UnitTests (117)
src\Analyzers\CSharp\Tests\ImplementInterface\ImplementInterfaceTests.cs (1)
4099LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\MakeAnonymousFunctionStatic\MakeAnonymousFunctionStaticTests.cs (1)
55LanguageVersion = LanguageVersion.CSharp8
src\Analyzers\CSharp\Tests\MakeLocalFunctionStatic\MakeLocalFunctionStaticTests.cs (1)
31private static readonly ParseOptions CSharp8ParseOptions = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8);
src\Analyzers\CSharp\Tests\NewLines\ConsecutiveBracePlacement\ConsecutiveBracePlacementTests.cs (4)
266LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 345LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 803LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 849LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\NewLines\MultipleBlankLines\MultipleBlankLinesTests.cs (10)
534LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 552LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 578LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 605LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 632LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 770LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 793LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 832LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 875LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 922LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\Nullable\CSharpDeclareAsNullableCodeFixTests.cs (1)
24private static readonly TestParameters s_nullableFeature = new TestParameters(parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\RemoveConfusingSuppression\RemoveConfusingSuppressionTests.cs (2)
104LanguageVersion = LanguageVersion.CSharp8 138LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\RemoveUnnecessaryCast\RemoveUnnecessaryCastTests.cs (6)
8301LanguageVersion = LanguageVersion.CSharp8 8349LanguageVersion = LanguageVersion.CSharp8 8397LanguageVersion = LanguageVersion.CSharp8, 8496LanguageVersion = LanguageVersion.CSharp8 8544LanguageVersion = LanguageVersion.CSharp8 8592LanguageVersion = LanguageVersion.CSharp8
src\Analyzers\CSharp\Tests\RemoveUnnecessaryDiscardDesignation\RemoveUnnecessaryDiscardDesignationTests.cs (1)
76LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\RemoveUnusedParametersAndValues\RemoveUnusedParametersTests.cs (1)
1387""", parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\RemoveUnusedParametersAndValues\RemoveUnusedValueAssignmentTests.cs (23)
2728""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 2767[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 3002""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 3008[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 3114""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 3120[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 3251""", optionName: optionName, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 5466""", optionName, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8229""", parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8245""", parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8269""", optionName: nameof(PreferDiscard), parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8293""", optionName: nameof(PreferDiscard), parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8313""", optionName: nameof(PreferDiscard), parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8464""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8470[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 8916""", options: PreferUnusedLocal, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 9118""", new TestParameters(options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8))); 9124[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 9156""", new TestParameters(options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8))); 9182""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 9228[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 9256[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 9300""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UpgradeProject\UpgradeProjectTests.cs (19)
77LanguageVersion.CSharp8, 91LanguageVersion.CSharp8, 351#error version:[|{{LanguageVersion.CSharp8.ToDisplayString()}}|] 371expected: LanguageVersion.CSharp8, 428LanguageVersion.CSharp8, 459LanguageVersion.CSharp8, 703new CSharpParseOptions(LanguageVersion.CSharp8)); 848expected: LanguageVersion.CSharp8, 890LanguageVersion.CSharp8, 904LanguageVersion.CSharp8, 918LanguageVersion.CSharp8, 931LanguageVersion.CSharp8, 964LanguageVersion.CSharp8, 993LanguageVersion.CSharp8, 1027LanguageVersion.CSharp8, 1065new CSharpParseOptions(LanguageVersion.CSharp8)); 1170new CSharpParseOptions(LanguageVersion.CSharp8)); 1215new CSharpParseOptions(LanguageVersion.CSharp8)); 1233new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UseCompoundAssignment\UseCompoundAssignmentTests.cs (2)
266LanguageVersion = LanguageVersion.CSharp8 307LanguageVersion = LanguageVersion.CSharp8
src\Analyzers\CSharp\Tests\UseCompoundAssignment\UseCompoundCoalesceAssignmentTests.cs (1)
31private static async Task TestMissingAsync(string testCode, LanguageVersion languageVersion = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseConditionalExpression\UseConditionalExpressionForAssignmentTests.cs (4)
26LanguageVersion languageVersion = LanguageVersion.CSharp8, 42LanguageVersion languageVersion = LanguageVersion.CSharp8, 987""", LanguageVersion.CSharp8, PreferImplicitTypeAlways); 1179""", LanguageVersion.CSharp8, PreferImplicitTypeAlways);
src\Analyzers\CSharp\Tests\UseConditionalExpression\UseConditionalExpressionForReturnTests.cs (5)
22private static readonly ParseOptions CSharp8 = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8); 977[InlineData(LanguageVersion.CSharp8, "(string)null")] 1043[InlineData(LanguageVersion.CSharp8, "(string)null")] 1078[InlineData(LanguageVersion.CSharp8, "(string)null")] 1113[InlineData(LanguageVersion.CSharp8, "(string)null")]
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForAccessorsAnalyzerTests.cs (3)
29LanguageVersion version = LanguageVersion.CSharp8) 51LanguageVersion version = LanguageVersion.CSharp8) 71LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForConstructorsAnalyzerTests.cs (1)
24private static async Task TestWithUseExpressionBody(string code, string fixedCode, LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForMethodsAnalyzerTests.cs (1)
25private static async Task TestWithUseExpressionBody(string code, string fixedCode, LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForPropertiesAnalyzerTests.cs (1)
25private static async Task TestWithUseExpressionBody(string code, string fixedCode, LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseImplicitObjectCreation\CSharpUseImplicitObjectCreationTests.cs (1)
35LanguageVersion = CodeAnalysis.CSharp.LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UseIndexOrRangeOperator\UseIndexOperatorTests.cs (2)
533LanguageVersion = LanguageVersion.CSharp8, 570LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UseIndexOrRangeOperator\UseRangeOperatorTests.cs (2)
100LanguageVersion = LanguageVersion.CSharp8, 137LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UseInterpolatedVerbatimString\UseInterpolatedVerbatimStringCodeFixTests.cs (1)
144""", parameters: new TestParameters().WithParseOptions(new CSharpParseOptions(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\UseIsNullCheck\UseIsNullCheckForCastAndEqualityOperatorTests.cs (3)
95new TestParameters(parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 175""", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)); 235""", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UseIsNullCheck\UseIsNullCheckForReferenceEqualsTests.cs (2)
27private static readonly ParseOptions CSharp8 = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8); 99new TestParameters(parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\UseIsNullCheck\UseNullCheckOverTypeCheckDiagnosticAnalyzerTests.cs (1)
34=> await VerifyAsync(source, fixedSource, LanguageVersion.CSharp8);
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpAsAndMemberAccessTests.cs (5)
155LanguageVersion = LanguageVersion.CSharp8, 197LanguageVersion = LanguageVersion.CSharp8, 265LanguageVersion = LanguageVersion.CSharp8, 360LanguageVersion = LanguageVersion.CSharp8, 383LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpAsAndNullCheckTests.cs (10)
43public async Task InlineTypeCheck1(string input, string output, LanguageVersion version = LanguageVersion.CSharp8) 59private async Task TestStatement(string input, string output, LanguageVersion version = LanguageVersion.CSharp8) 1166""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1205""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1471""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1502""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1557""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1589""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1652""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1694""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpAsAndNullCheckTests_FixAllTests.cs (1)
72""", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpUseNotPatternTests.cs (1)
304LanguageVersion = LanguageVersion.CSharp8,
Microsoft.CodeAnalysis.CSharp.CommandLine.UnitTests (6)
CommandLineTests.cs (6)
1604[InlineData("8", LanguageVersion.CSharp8)] 1605[InlineData("8.0", LanguageVersion.CSharp8)] 1788InlineData(LanguageVersion.CSharp8, LanguageVersion.CSharp8), 1831InlineData("8", true, LanguageVersion.CSharp8), 1832InlineData("8.0", true, LanguageVersion.CSharp8),
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (19)
Classification\SyntacticClassifierTests.cs (1)
3094[new CSharpParseOptions(LanguageVersion.CSharp8)],
CodeActions\GenerateEqualsAndGetHashCodeFromMembers\GenerateEqualsAndGetHashCodeFromMembersTests.cs (5)
2776LanguageVersion = LanguageVersion.CSharp8, 2825LanguageVersion = LanguageVersion.CSharp8, 2962LanguageVersion = LanguageVersion.CSharp8, 3055LanguageVersion = LanguageVersion.CSharp8, 3105LanguageVersion = LanguageVersion.CSharp8,
CodeActions\InitializeParameter\AddParameterCheckTests.cs (2)
245[InlineData(LanguageVersion.CSharp8)] 291[InlineData(LanguageVersion.CSharp8)]
Completion\CompletionProviders\DeclarationNameCompletionProviderTests.cs (9)
611[InlineData(LanguageVersion.CSharp8)] 630if (languageVersion.MapSpecifiedToEffectiveVersion() >= LanguageVersion.CSharp8) 641[InlineData(LanguageVersion.CSharp8)] 661if (languageVersion.MapSpecifiedToEffectiveVersion() >= LanguageVersion.CSharp8) 672[InlineData(LanguageVersion.CSharp8)] 692if (languageVersion.MapSpecifiedToEffectiveVersion() >= LanguageVersion.CSharp8) 2597[InlineData(LanguageVersion.CSharp8)] 2616if (languageVersion.MapSpecifiedToEffectiveVersion() >= LanguageVersion.CSharp8) 2628[InlineData(LanguageVersion.CSharp8)]
QuickInfo\SemanticQuickInfoSourceTests.cs (2)
3248Options.Regular.WithLanguageVersion(LanguageVersion.CSharp8), 3288Options.Regular.WithLanguageVersion(LanguageVersion.CSharp8),
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (1)
PDB\CSharpDeterministicBuildCompilationTests.cs (1)
353languageVersion: LanguageVersion.CSharp8,
Microsoft.CodeAnalysis.CSharp.Features (20)
CodeRefactorings\EnableNullable\EnableNullableCodeRefactoringProvider.cs (1)
64ParseOptions: CSharpParseOptions { LanguageVersion: >= LanguageVersion.CSharp8 },
ConvertIfToSwitch\CSharpConvertIfToSwitchCodeRefactoringProvider.cs (1)
32(version >= LanguageVersion.CSharp8 ? Feature.SwitchExpression : 0) |
ExtractMethod\CSharpMethodExtractor.CSharpCodeGenerator.cs (2)
172=> node.SyntaxTree.Options.LanguageVersion() < LanguageVersion.CSharp8; 219if (LocalFunction && (!Options.PreferStaticLocalFunction.Value || languageVersion < LanguageVersion.CSharp8))
IntroduceUsingStatement\CSharpIntroduceUsingStatementCodeRefactoringProvider.cs (1)
101options.LanguageVersion() < LanguageVersion.CSharp8)
MetadataAsSource\CSharpMetadataAsSourceService.cs (1)
107if (options.LanguageVersion < LanguageVersion.CSharp8)
QuickInfo\CSharpSemanticQuickInfoProvider.cs (1)
90if (parseOptions.LanguageVersion < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionDiagnosticAnalyzer.cs (1)
35if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\MakeLocalFunctionStatic\MakeLocalFunctionStaticHelper.cs (1)
15=> languageVersion >= LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\MakeStructMemberReadOnly\CSharpMakeStructMemberReadOnlyAnalyzer.cs (1)
38if (compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\RemoveUnnecessaryNullableDirective\CSharpRemoveRedundantNullableDirectiveDiagnosticAnalyzer.cs (1)
37if (compilation.LanguageVersion < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseCompoundAssignment\CSharpUseCompoundAssignmentDiagnosticAnalyzer.cs (1)
27options.LanguageVersion() >= LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\UseCompoundAssignment\CSharpUseCompoundCoalesceAssignmentDiagnosticAnalyzer.cs (1)
46if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseIndexOperatorDiagnosticAnalyzer.cs (1)
64if (compilation.LanguageVersion < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseRangeOperatorDiagnosticAnalyzer.cs (1)
57if (compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UseIsNullCheck\CSharpUseIsNullCheckForReferenceEqualsDiagnosticAnalyzer.cs (1)
25=> compilation.LanguageVersion() >= LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\UsePatternMatching\CSharpAsAndMemberAccessDiagnosticAnalyzer.cs (1)
46if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\Analyzers\UsePatternMatching\UsePatternMatchingHelpers.cs (1)
24requiredLanguageVersion = LanguageVersion.CSharp8;
src\Analyzers\CSharp\Analyzers\UseSimpleUsingStatement\UseSimpleUsingStatementDiagnosticAnalyzer.cs (1)
70if (context.Compilation.LanguageVersion() < LanguageVersion.CSharp8)
src\Analyzers\CSharp\CodeFixes\UseLocalFunction\CSharpUseLocalFunctionCodeFixProvider.cs (1)
89if (languageVersion >= LanguageVersion.CSharp8)
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (150)
ConvertAnonymousType\ConvertAnonymousTypeToClassTests.cs (1)
20private static readonly ParseOptions CSharp8 = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8);
ConvertForToForEach\ConvertForToForEachTests.cs (1)
1768""", parameters: new TestParameters(new CSharpParseOptions(LanguageVersion.CSharp8)));
ConvertIfToSwitch\ConvertIfToSwitchTests.cs (12)
315LanguageVersion = LanguageVersion.CSharp8, 498[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 513LanguageVersion.CSharp8 => 627LanguageVersion = LanguageVersion.CSharp8, 668LanguageVersion = LanguageVersion.CSharp8, 1547LanguageVersion = LanguageVersion.CSharp8, 1639LanguageVersion = LanguageVersion.CSharp8, 1731LanguageVersion = LanguageVersion.CSharp8, 1823LanguageVersion = LanguageVersion.CSharp8, 2431LanguageVersion = LanguageVersion.CSharp8, 2500LanguageVersion = LanguageVersion.CSharp8, 2617LanguageVersion = LanguageVersion.CSharp8,
ConvertLinq\ConvertLinqQueryToForEachTests.cs (1)
4471await TestInRegularAndScriptAsync(source, output, parseOptions: new CSharpParseOptions(CodeAnalysis.CSharp.LanguageVersion.CSharp8));
ConvertProgram\ConvertToTopLevelStatementsAnalyzerTests.cs (1)
69LanguageVersion = LanguageVersion.CSharp8,
ConvertProgram\ConvertToTopLevelStatementsRefactoringTests.cs (1)
164LanguageVersion = LanguageVersion.CSharp8,
ExtractMethod\ExtractLocalFunctionTests.cs (1)
3637""", CodeActionIndex, new TestParameters(options: Option(CSharpCodeStyleOptions.PreferStaticLocalFunction, CodeStyleOption2.TrueWithSilentEnforcement), parseOptions: TestOptions.Regular.WithLanguageVersion(LanguageVersion.CSharp8)));
InlineTemporary\InlineTemporaryTests.cs (3)
387[InlineData(LanguageVersion.CSharp8)] 415[InlineData(LanguageVersion.CSharp8, " (int?)42")] 5094await TestMissingInRegularAndScriptAsync(code, new TestParameters(parseOptions: TestOptions.Regular.WithLanguageVersion(LanguageVersion.CSharp8)));
IntroduceUsingStatement\IntroduceUsingStatementTests.cs (6)
503""", LanguageVersion.CSharp8); 1284""", LanguageVersion.CSharp8); 1314""", LanguageVersion.CSharp8); 1346""", LanguageVersion.CSharp8); 1390""", LanguageVersion.CSharp8); 1436""", LanguageVersion.CSharp8);
InvertIf\InvertIfTests.cs (2)
1234""", LanguageVersion.CSharp8); 1309""", LanguageVersion.CSharp8);
InvertLogical\InvertLogicalTests.cs (1)
20private static readonly ParseOptions CSharp8 = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8);
MakeLocalFunctionStatic\MakeLocalFunctionStaticRefactoringTests.cs (1)
23private static readonly ParseOptions CSharp8ParseOptions = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8);
MakeLocalFunctionStatic\PassInCapturedVariablesAsArgumentsCodeFixProviderTests.cs (1)
30private static readonly ParseOptions CSharp8ParseOptions = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8);
RemoveUnnecessaryCast\RemoveUnnecessaryCastTests_AsTests.cs (1)
1453""", new TestParameters(parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\ImplementInterface\ImplementInterfaceTests.cs (1)
4099LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\MakeAnonymousFunctionStatic\MakeAnonymousFunctionStaticTests.cs (1)
55LanguageVersion = LanguageVersion.CSharp8
src\Analyzers\CSharp\Tests\MakeLocalFunctionStatic\MakeLocalFunctionStaticTests.cs (1)
31private static readonly ParseOptions CSharp8ParseOptions = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8);
src\Analyzers\CSharp\Tests\NewLines\ConsecutiveBracePlacement\ConsecutiveBracePlacementTests.cs (4)
266LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 345LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 803LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 849LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\NewLines\MultipleBlankLines\MultipleBlankLinesTests.cs (10)
534LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 552LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 578LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 605LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 632LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 770LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 793LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 832LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 875LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8, 922LanguageVersion = Microsoft.CodeAnalysis.CSharp.LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\Nullable\CSharpDeclareAsNullableCodeFixTests.cs (1)
24private static readonly TestParameters s_nullableFeature = new TestParameters(parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\RemoveConfusingSuppression\RemoveConfusingSuppressionTests.cs (2)
104LanguageVersion = LanguageVersion.CSharp8 138LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\RemoveUnnecessaryCast\RemoveUnnecessaryCastTests.cs (6)
8301LanguageVersion = LanguageVersion.CSharp8 8349LanguageVersion = LanguageVersion.CSharp8 8397LanguageVersion = LanguageVersion.CSharp8, 8496LanguageVersion = LanguageVersion.CSharp8 8544LanguageVersion = LanguageVersion.CSharp8 8592LanguageVersion = LanguageVersion.CSharp8
src\Analyzers\CSharp\Tests\RemoveUnnecessaryDiscardDesignation\RemoveUnnecessaryDiscardDesignationTests.cs (1)
76LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\RemoveUnusedParametersAndValues\RemoveUnusedParametersTests.cs (1)
1387""", parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\RemoveUnusedParametersAndValues\RemoveUnusedValueAssignmentTests.cs (23)
2728""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 2767[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 3002""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 3008[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 3114""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 3120[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 3251""", optionName: optionName, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 5466""", optionName, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8229""", parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8245""", parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8269""", optionName: nameof(PreferDiscard), parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8293""", optionName: nameof(PreferDiscard), parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8313""", optionName: nameof(PreferDiscard), parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8464""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 8470[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 8916""", options: PreferUnusedLocal, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 9118""", new TestParameters(options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8))); 9124[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 9156""", new TestParameters(options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8))); 9182""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8)); 9228[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 9256[CombinatorialValues(LanguageVersion.CSharp8, LanguageVersion.CSharp9)] LanguageVersion languageVersion) 9300""", options: PreferDiscard, parseOptions: new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UpgradeProject\UpgradeProjectTests.cs (19)
77LanguageVersion.CSharp8, 91LanguageVersion.CSharp8, 351#error version:[|{{LanguageVersion.CSharp8.ToDisplayString()}}|] 371expected: LanguageVersion.CSharp8, 428LanguageVersion.CSharp8, 459LanguageVersion.CSharp8, 703new CSharpParseOptions(LanguageVersion.CSharp8)); 848expected: LanguageVersion.CSharp8, 890LanguageVersion.CSharp8, 904LanguageVersion.CSharp8, 918LanguageVersion.CSharp8, 931LanguageVersion.CSharp8, 964LanguageVersion.CSharp8, 993LanguageVersion.CSharp8, 1027LanguageVersion.CSharp8, 1065new CSharpParseOptions(LanguageVersion.CSharp8)); 1170new CSharpParseOptions(LanguageVersion.CSharp8)); 1215new CSharpParseOptions(LanguageVersion.CSharp8)); 1233new CSharpParseOptions(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UseCompoundAssignment\UseCompoundAssignmentTests.cs (2)
266LanguageVersion = LanguageVersion.CSharp8 307LanguageVersion = LanguageVersion.CSharp8
src\Analyzers\CSharp\Tests\UseCompoundAssignment\UseCompoundCoalesceAssignmentTests.cs (1)
31private static async Task TestMissingAsync(string testCode, LanguageVersion languageVersion = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseConditionalExpression\UseConditionalExpressionForAssignmentTests.cs (4)
26LanguageVersion languageVersion = LanguageVersion.CSharp8, 42LanguageVersion languageVersion = LanguageVersion.CSharp8, 987""", LanguageVersion.CSharp8, PreferImplicitTypeAlways); 1179""", LanguageVersion.CSharp8, PreferImplicitTypeAlways);
src\Analyzers\CSharp\Tests\UseConditionalExpression\UseConditionalExpressionForReturnTests.cs (5)
22private static readonly ParseOptions CSharp8 = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8); 977[InlineData(LanguageVersion.CSharp8, "(string)null")] 1043[InlineData(LanguageVersion.CSharp8, "(string)null")] 1078[InlineData(LanguageVersion.CSharp8, "(string)null")] 1113[InlineData(LanguageVersion.CSharp8, "(string)null")]
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForAccessorsAnalyzerTests.cs (3)
29LanguageVersion version = LanguageVersion.CSharp8) 51LanguageVersion version = LanguageVersion.CSharp8) 71LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForConstructorsAnalyzerTests.cs (1)
24private static async Task TestWithUseExpressionBody(string code, string fixedCode, LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForMethodsAnalyzerTests.cs (1)
25private static async Task TestWithUseExpressionBody(string code, string fixedCode, LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseExpressionBody\UseExpressionBodyForPropertiesAnalyzerTests.cs (1)
25private static async Task TestWithUseExpressionBody(string code, string fixedCode, LanguageVersion version = LanguageVersion.CSharp8)
src\Analyzers\CSharp\Tests\UseImplicitObjectCreation\CSharpUseImplicitObjectCreationTests.cs (1)
35LanguageVersion = CodeAnalysis.CSharp.LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UseIndexOrRangeOperator\UseIndexOperatorTests.cs (2)
533LanguageVersion = LanguageVersion.CSharp8, 570LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UseIndexOrRangeOperator\UseRangeOperatorTests.cs (2)
100LanguageVersion = LanguageVersion.CSharp8, 137LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UseInterpolatedVerbatimString\UseInterpolatedVerbatimStringCodeFixTests.cs (1)
144""", parameters: new TestParameters().WithParseOptions(new CSharpParseOptions(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\UseIsNullCheck\UseIsNullCheckForCastAndEqualityOperatorTests.cs (3)
95new TestParameters(parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 175""", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)); 235""", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UseIsNullCheck\UseIsNullCheckForReferenceEqualsTests.cs (2)
27private static readonly ParseOptions CSharp8 = CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8); 99new TestParameters(parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\UseIsNullCheck\UseNullCheckOverTypeCheckDiagnosticAnalyzerTests.cs (1)
34=> await VerifyAsync(source, fixedSource, LanguageVersion.CSharp8);
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpAsAndMemberAccessTests.cs (5)
155LanguageVersion = LanguageVersion.CSharp8, 197LanguageVersion = LanguageVersion.CSharp8, 265LanguageVersion = LanguageVersion.CSharp8, 360LanguageVersion = LanguageVersion.CSharp8, 383LanguageVersion = LanguageVersion.CSharp8,
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpAsAndNullCheckTests.cs (10)
43public async Task InlineTypeCheck1(string input, string output, LanguageVersion version = LanguageVersion.CSharp8) 59private async Task TestStatement(string input, string output, LanguageVersion version = LanguageVersion.CSharp8) 1166""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1205""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1471""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1502""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1557""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1589""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1652""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8))); 1694""", parameters: new TestParameters(CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)));
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpAsAndNullCheckTests_FixAllTests.cs (1)
72""", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8));
src\Analyzers\CSharp\Tests\UsePatternMatching\CSharpUseNotPatternTests.cs (1)
304LanguageVersion = LanguageVersion.CSharp8,
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (7)
ScriptOptionsTests.cs (5)
22var options = ScriptOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8); 23Assert.Equal(LanguageVersion.CSharp8, ((CSharpParseOptions)options.ParseOptions).LanguageVersion); 29var options = ScriptOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8); 30Assert.Same(options, options.WithLanguageVersion(LanguageVersion.CSharp8)); 37Assert.Throws<InvalidOperationException>(() => options.WithLanguageVersion(LanguageVersion.CSharp8));
ScriptTests.cs (2)
969string x = null;", ScriptOptions.WithLanguageVersion(LanguageVersion.CSharp8)); 991var script = CSharpScript.Create(code, ScriptOptions.WithLanguageVersion(LanguageVersion.CSharp8));
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (7)
Semantics\NullableReferenceTypesTests.cs (2)
81300parseOptions: TestOptions.Script.WithLanguageVersion(LanguageVersion.CSharp8)); 81371var comp = CreateCompilationWithMscorlib40AndSystemCore(new[] { source }, parseOptions: TestOptions.Script.WithLanguageVersion(LanguageVersion.CSharp8));
Semantics\TargetTypedConditionalOperatorTests.cs (4)
180foreach (var langVersion in new[] { LanguageVersion.CSharp8, MessageID.IDS_FeatureTargetTypedConditional.RequiredVersion() }) 205foreach (var langVersion in new[] { LanguageVersion.CSharp8, MessageID.IDS_FeatureTargetTypedConditional.RequiredVersion() }) 227foreach (var langVersion in new[] { LanguageVersion.CSharp8, MessageID.IDS_FeatureTargetTypedConditional.RequiredVersion() }) 263foreach (var langVersion in new[] { LanguageVersion.CSharp8, MessageID.IDS_FeatureTargetTypedConditional.RequiredVersion() })
SourceGeneration\GeneratorDriverTests.cs (1)
3596parseOptions = parseOptions.WithLanguageVersion(LanguageVersion.CSharp8);
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (9)
Parsing\AsyncStreamsParsingTests.cs (2)
22return SyntaxFactory.ParseSyntaxTree(text, options: (options ?? TestOptions.Regular).WithLanguageVersion(LanguageVersion.CSharp8)); 27return SyntaxFactory.ParseExpression(text, options: (options ?? TestOptions.Regular).WithLanguageVersion(LanguageVersion.CSharp8));
Parsing\DeclarationScopeParsingTests.cs (3)
3249[InlineData(LanguageVersion.CSharp8)] 3260if (langVersion == LanguageVersion.CSharp8) 14215[InlineData(LanguageVersion.CSharp8)]
Parsing\ExpressionParsingTests.cs (2)
241}}", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)).VerifyDiagnostics(); 316}}", parseOptions: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8)).VerifyDiagnostics();
Parsing\PatternParsingTests.cs (2)
22UsingStatement(text, options: CSharpParseOptions.Default.WithLanguageVersion(LanguageVersion.CSharp8), expectedErrors); 6578foreach (var langVersion in new[] { LanguageVersion.CSharp6, LanguageVersion.CSharp7, LanguageVersion.CSharp8 })
Microsoft.CodeAnalysis.CSharp.Test.Utilities (2)
TestOptions.cs (2)
40public static readonly CSharpParseOptions Regular8 = Regular.WithLanguageVersion(LanguageVersion.CSharp8); 51public static readonly CSharpParseOptions WithoutCovariantReturns = Regular.WithLanguageVersion(LanguageVersion.CSharp8);
Microsoft.CodeAnalysis.CSharp.Workspaces (2)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\LanguageServices\CSharpSemanticFactsService.cs (2)
46if (semanticModel.Compilation.LanguageVersion().MapSpecifiedToEffectiveVersion() >= LanguageVersion.CSharp8) 68var isLanguageVersionGreaterOrEqualToCSharp8 = (semanticModel.Compilation as CSharpCompilation)?.LanguageVersion >= LanguageVersion.CSharp8;
Microsoft.Extensions.Logging.Generators (2)
LoggerMessageGenerator.Parser.cs (2)
594if (results.Count > 0 && _compilation is CSharpCompilation { LanguageVersion : LanguageVersion version and < LanguageVersion.CSharp8 }) 597Diag(DiagnosticDescriptors.LoggingUnsupportedLanguageVersion, null, version.ToDisplayString(), LanguageVersion.CSharp8.ToDisplayString());
Microsoft.Extensions.Options.SourceGeneration (2)
Parser.cs (2)
151if (results.Count > 0 && _compilation is CSharpCompilation { LanguageVersion : LanguageVersion version and < LanguageVersion.CSharp8 }) 154Diag(DiagDescriptors.OptionsUnsupportedLanguageVersion, null, version.ToDisplayString(), LanguageVersion.CSharp8.ToDisplayString());
Microsoft.VisualStudio.LanguageServices.CSharp.UnitTests (6)
ProjectSystemShim\CPS\AdditionalPropertiesTests.cs (3)
45[InlineData(LanguageVersion.CSharp8)] 53const LanguageVersion attemptedVersion = LanguageVersion.CSharp8; 80const LanguageVersion attemptedVersion = LanguageVersion.CSharp8;
ProjectSystemShim\LegacyProject\CSharpCompilerOptionsTests.cs (3)
170[InlineData(LanguageVersion.CSharp8)] 193const LanguageVersion attemptedVersion = LanguageVersion.CSharp8; 224const LanguageVersion attemptedVersion = LanguageVersion.CSharp8;