So I'm trying to utilize C# 8 in my .NET 4 web application by adding two entries in my .csproj
file right inside the PropertyGroup
node.
<LangVersion>8.0</LangVersion>
<Nullable>enable</Nullable>
But for some reason when I try to do string? name = "";
I still get an error stating "Error CS8370 Feature 'nullable reference types' is not available in C# 7.3. Please use language version 8.0 or greater."
I'm using Visual Studio 2022 17.0.4.
Why is it that I get this error?