-
Notifications
You must be signed in to change notification settings - Fork 131
Annotate Serilog.Settings.Configuration as not trim-compatible #371
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
base: dev
Are you sure you want to change the base?
Changes from 3 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ | |
<Description>Microsoft.Extensions.Configuration (appsettings.json) support for Serilog.</Description> | ||
<VersionPrefix>4.0.0</VersionPrefix> | ||
<Authors>Serilog Contributors</Authors> | ||
<TargetFrameworks>netstandard2.0;net461</TargetFrameworks> | ||
<TargetFrameworks>net7.0;netstandard2.0;net461</TargetFrameworks> | ||
<GenerateDocumentationFile>true</GenerateDocumentationFile> | ||
<AssemblyName>Serilog.Settings.Configuration</AssemblyName> | ||
<PackageTags>serilog;json</PackageTags> | ||
|
@@ -15,6 +15,10 @@ | |
<EmbedUntrackedSources>true</EmbedUntrackedSources> | ||
<IncludeSymbols>true</IncludeSymbols> | ||
<SymbolPackageFormat>snupkg</SymbolPackageFormat> | ||
<IsTrimmable>true</IsTrimmable> | ||
<EnableAotAnalyzer>true</EnableAotAnalyzer> | ||
<EnableSingleFileAnalyzer>true</EnableSingleFileAnalyzer> | ||
<PolySharpIncludeRuntimeSupportedAttributes>true</PolySharpIncludeRuntimeSupportedAttributes> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Likely has a negligible impact, but if you want to minimize the size impact of PolySharp as much as possible here you can optionally get it to only polyfill the types you're actually using, instead of all available ones, which is the default. You can do so by adding the following MSBuild property here: <PolySharpIncludeGeneratedTypes>
System.Diagnostics.CodeAnalysis.RequiresUnreferencedCodeAttribute;
System.Diagnostics.CodeAnalysis.RequiresDynamicCodeAttribute;
System.Diagnostics.CodeAnalysis.RequiresAssemblyFilesAttribute;
</PolySharpIncludeGeneratedTypes> |
||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
|
||
using System.Data; | ||
|
||
namespace Serilog | ||
{ | ||
internal static class TrimWarningMessages | ||
{ | ||
public const string NotSupportedWhenTrimming = "Automatic configuration is not supported when trimming."; | ||
public const string NotSupportedInAot = "Automatic configuration is not supported when AOT compiling."; | ||
public const string UnboundedReflection = "Uses unbounded reflection to load types"; | ||
public const string CreatesArraysOfArbitraryTypes = "Creates arrays of arbitrary types"; | ||
} | ||
} |
Uh oh!
There was an error while loading. Please reload this page.