Skip to content

Commit 70cedbf

Browse files
committed
Signal AOT compatibility
Added IsAotCompatible property to Collections.Pooled.csproj for AOT support. Updated Directory.Build.props to suppress NETSDK1210 warning alongside CS1591. Ran AOT analyzers in test environment and everything came back green.
1 parent dd81f80 commit 70cedbf

4 files changed

Lines changed: 7 additions & 2 deletions

File tree

.github/workflows/dotnet.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
- name: Setup .NET SDK
3636
uses: actions/setup-dotnet@v5
3737
with:
38-
dotnet-version: "9.0.x"
38+
dotnet-version: "10.0.x"
3939

4040
- name: Run Tests
4141
run: dotnet test ./Collections.Pooled.Tests/Collections.Pooled.Tests.csproj

Collections.Pooled.Tests/PooledStack/Stack.Generic.Tests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public void Stack_Generic_Constructor_IEnumerable(EnumerableType enumerableType,
8383
IEnumerable<T> enumerable = CreateEnumerable(enumerableType, null, enumerableLength, 0, numberOfDuplicateElements);
8484
PooledStack<T> stack = new PooledStack<T>(enumerable);
8585
RegisterForDispose(stack);
86-
Assert.Equal(enumerable.ToArray().Reverse(), stack.ToArray());
86+
Assert.Equal(enumerable.Reverse().ToArray(), stack.ToArray());
8787
}
8888

8989
[Fact]

Collections.Pooled/Collections.Pooled.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@
1212
<DebugSymbols>true</DebugSymbols>
1313
</PropertyGroup>
1414

15+
<PropertyGroup>
16+
<IsAotCompatible>true</IsAotCompatible>
17+
</PropertyGroup>
18+
1519
<ItemGroup>
1620
<None Include="..\LICENSE" Pack="true" PackagePath="" Visible="false" />
1721
<None Include="..\README.md" Pack="true" PackagePath="" />

Directory.Build.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<Project>
22
<PropertyGroup>
33
<NoWarn>$(NoWarn);CS1591</NoWarn>
4+
<NoWarn>$(NoWarn);NETSDK1210</NoWarn>
45
</PropertyGroup>
56
</Project>

0 commit comments

Comments
 (0)