Skip to content

Commit

Permalink
Enable C# compiler strict mode by default
Browse files Browse the repository at this point in the history
  • Loading branch information
kzu authored Nov 16, 2022
1 parent 2916efd commit ef8e7fa
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@
<DebugType>embedded</DebugType>
<DebugSymbols>true</DebugSymbols>
<Nullable>enable</Nullable>

<!-- See https://www.meziantou.net/csharp-compiler-strict-mode.htm -->
<Features>strict</Features>

<!-- Simplify namespaces by defaulting to the single root name -->
<RootNamespace>$(MSBuildProjectName)</RootNamespace>
<RootNamespaceDot>$(MSBuildProjectName.IndexOf('.'))</RootNamespaceDot>
Expand Down

0 comments on commit ef8e7fa

Please sign in to comment.