Philip Lee created THRIFT-5578:
----------------------------------
Summary: Thrift compiler emits #nullable disable for C# 7
Key: THRIFT-5578
URL: https://issues.apache.org/jira/browse/THRIFT-5578
Project: Thrift
Issue Type: Improvement
Components: Compiler (General)
Affects Versions: 0.16.0
Reporter: Philip Lee
The thrift compiler 0.16 emits
#nullable disable // suppress C# 8.0 nullable contexts (we still
support earlier versions)
However since you're supporting .NET Standard your Nuget package can be used
for .NET Framework projects which use C# version <= 7.3.
This then causes an error
Error CS8370 Feature 'nullable reference types' is not available in C#
7.3. Please use language version 8.0 or greater.
It should be possible to prevent the compiler emitting this pragma.
Of course a work around is to edit the project file and set
<LangVersion>8.0</LangVersion>, but this shouldn't be necessary.
--
This message was sent by Atlassian Jira
(v8.20.7#820007)