Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,11 @@
<ImplicitUsings>disable</ImplicitUsings>
<!-- NOTE: Top-Level statements blocked as an error in .editorconfig and ImplicitUsings 'feature' VERIFIED in the targets file -->
</PropertyGroup>

<!--
Apply SyleCop settings to all projects; It is at least plausible to do this in a .editorconfig but there's no docs on
how. Only a PR and multiple bugs/discussions pointing to it. It's too big to decipher to make it worth using. Docs please.
-->
<ItemGroup Condition="'$(NoCommonAnalyzers)'!='true'">
<AdditionalFiles Include="$(MSBuildThisFileDirectory)stylecop.json" Link="stylecop.json" />
</ItemGroup>
Expand Down
7 changes: 7 additions & 0 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
<Project InitialTargets="VerifyProjectSettings;ShowBuildParameters;EnsureBuildOutputPaths">

<!--This must go in the targets as the directory imports occur BEFORE $(NETCoreSdkVersion) is set and would end up blank -->
<PropertyGroup Condition="'$(NETCoreSdkVersion)'!='' AND $([MSBuild]::VersionGreaterThanOrEquals('$(NETCoreSdkVersion)', '10.0.0'))">
<DefineConstants>$(DefineConstants);NET_SDK_10_OR_GREATER</DefineConstants>
</PropertyGroup>

<!--
Since Nuget.config is configured to include the build output location this
will ensure the folder exists during restore so that it won't fail.
Expand All @@ -19,6 +25,7 @@
<Message Importance="normal" Text=" FileVersion: $(FileVersion)"/>
<Message Importance="normal" Text=" Platform: $(Platform)"/>
<Message Importance="normal" Text=" Configuration: $(Configuration)"/>
<Message Importance="normal" Text=" NETCoreSdkVersion: $(NETCoreSdkVersion)"/>
</Target>

<Target Name="VerifyProjectSettings" Condition="'$(MSBuildProjectExtension)'=='.csproj'">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

// This isn't a normal built-in define; but follows the pattern for built-in defines and expresses the intent.
// There is no Known way to "light up" at runtime for functionality available in newer versions
#if COMPILER_5_OR_GREATER
// See: Directory.Build.targets for how this is set. (Roslyn compiler v5.x is included in .NET 10)
#if NET_SDK_10_OR_GREATER
using System.Threading.Tasks;

using Microsoft.CodeAnalysis;
Expand Down
3 changes: 2 additions & 1 deletion src/Analyzers/RepositoryVerifier/ExtensionKeywordAnalyzer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

// This isn't a normal built-in define; but follows the pattern for built-in defines and expresses the intent.
// There is no Known way to "light up" at runtime for functionality available in newer versions
#if COMPILER_5_OR_GREATER
// See: Directory.Build.targets for how this is set. (Roslyn compiler v5.x is included in .NET 10)
#if NET_SDK_10_OR_GREATER
using System.Collections.Immutable;

using Microsoft.CodeAnalysis;
Expand Down
19 changes: 10 additions & 9 deletions src/Interop/Ubiquity.NET.Llvm.Interop/ReadMe.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@ This library contains the low level interop between managed code and the native
for more info]

Firstly it's young, poorly understood, barely even documented and not what is considered
by many as stable/mature yet. But, mostly because it requires everything to compile AOT to work. That
is, it's all or nothing and doesn't support use in an either or model (traditional JIT runtime,
or AOT). Somethings are not yet supporting AOT/Trimming scenarios. (In the case of the samples
in this repo the DGML graph builder used employs XML serialization, which in turn requires
dynamic reflection to work. This required a custom solution to resolve. So, as great a feature
AOT is it is not without issues at present. Perhaps over time it will become the normal state
and more libraries will build in a way as to support it. (This library has a motivation to go
there in that it's broader use is specifically for AOT code generation! Thus it's a bit on the
"bleeding edge" of things.)
by many as stable/mature yet. But, mostly because it requires everything to compile AOT to
work. That is, it's all or nothing and doesn't support use in an either or model
(traditional JIT runtime, or AOT). Somethings are not yet supporting AOT/Trimming scenarios.

In the case of the samples in this repo the DGML graph builder used employs XML
serialization, which in turn requires dynamic reflection to work. This required a custom
solution to resolve. So, as great a feature AOT is it is not without issues at present.
Perhaps over time it will become the normal state and more libraries will build in a way as
to support it. (This library has a motivation to go there in that it's broader use is
specifically for AOT code generation! Thus it's a bit on the "bleeding edge" of things.)
Loading