-
Notifications
You must be signed in to change notification settings - Fork 114
Removes all preprocessor statements and defined constants #1720
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| </PropertyGroup> | ||
|
|
||
| <ItemGroup> | ||
| <PackageReference Include="Microsoft.DotNet.Analyzers.Compatibility" Version="0.2.12-alpha"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't need this as there is no cross-framework compatibility to worry about anymore
| <TreatWarningsAsErrors>true</TreatWarningsAsErrors> | ||
| </PropertyGroup> | ||
| <PropertyGroup Condition=" '$(Configuration)' == 'Debug' "> | ||
| <DefineConstants>$(DefineConstants);DEBUG</DefineConstants> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DEBUG is an implicitly defined constant for this configuration
| using (var basisFile = new TemporaryFile(PackageBuilder.BuildSamplePackage("Acme.Web", "1.0.0"))) | ||
| using (var signatureFile = new TemporaryFile(basisFile.FilePath + ".octosig")) | ||
| { | ||
| #if USE_OCTODIFF_EXE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What dictates USE_OCTODIFF_EXE?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was a pre-processor constant for .NET 4.6.2... Example in 2025.4
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It maybe have been removed in #1669
| static SubstitutionsFixture() | ||
| { | ||
| #if NETCORE | ||
| Encoding.RegisterProvider(CodePagesEncodingProvider.Instance); // Required to use code pages in .NET Standard |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Kill the comment - it's superfluous
Jtango18
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor nit-needles in the haystack, otherwise...looks dope! SHIP IT!
Now that every project is .NET 8 and there is no .NET Framework, we can remove any pre-processor
#ifstatements and extra defined constants.ref MD-1413