Make rootNamespace non-nullable

This commit is contained in:
Dustin Campbell 2024-10-16 13:34:52 -07:00
Родитель 473b6d40fb
Коммит 9e66c0ccd5
1 изменённых файлов: 2 добавлений и 6 удалений

Просмотреть файл

@ -80,11 +80,7 @@ internal static class RazorProjectInfoFactory
fileSystem,
configure: builder =>
{
if (rootNamespace is not null)
{
builder.SetRootNamespace(rootNamespace);
}
builder.SetRootNamespace(rootNamespace);
builder.SetCSharpLanguageVersion(csharpLanguageVersion);
builder.SetSupportLocalizedComponentNames(); // ProjectState in MS.CA.Razor.Workspaces does this, so I'm doing it too
});
@ -101,7 +97,7 @@ internal static class RazorProjectInfoFactory
documents: documents);
}
private static (RazorConfiguration configuration, string? rootNamespace) ComputeRazorConfigurationOptions(AnalyzerConfigOptionsProvider options, Compilation compilation)
private static (RazorConfiguration configuration, string rootNamespace) ComputeRazorConfigurationOptions(AnalyzerConfigOptionsProvider options, Compilation compilation)
{
// See RazorSourceGenerator.RazorProviders.cs