Skip to content

Commit 8cfc49b

Browse files
committed
🔖 Chasm.Compatibility v2.5.0
1 parent 8621d58 commit 8cfc49b

File tree

6 files changed

+36
-2
lines changed

6 files changed

+36
-2
lines changed

.github/workflows/publish-compat.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ on:
1717
- Chasm.Compatibility.IndexRange
1818
- Chasm.Compatibility.ValueTuple
1919
- Chasm.Compatibility.HashCode
20+
- Chasm.Compatibility.Unsafe
2021

2122
jobs:
2223
publish-package:

Chasm.Compatibility/Chasm.Compatibility.Unsafe/Unsafe.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// ReSharper disable CommentTypo GrammarMistakeInComment
22

3-
#if (NETSTANDARD1_0_OR_GREATER || NET45_OR_GREATER || NETCOREAPP1_0_OR_GREATER)
3+
#if NETCOREAPP1_0_OR_GREATER || NETSTANDARD1_0_OR_GREATER || NET45_OR_GREATER
44
using System.Runtime.CompilerServices;
55
[assembly: TypeForwardedTo(typeof(Unsafe))]
66
#else

Chasm.Compatibility/Chasm.Compatibility/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Chasm.Compatibility Changelog
22

3+
### v2.5.0
4+
- ⬆️ Chasm.Compatibility.Unsafe v2.0.0;
5+
- ♻️ Refactored dependencies for target frameworks;
6+
37
### v2.4.1
48
- ⬆️ Chasm.Compatibility.Attributes v2.1.2;
59
- ⬆️ Chasm.Compatibility.HashCode v2.1.1;

Chasm.Compatibility/Chasm.Compatibility/Chasm.Compatibility.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
<!-- Header -->
3333
<AssemblyName>Chasm.Compatibility</AssemblyName>
3434
<PackageId>$(AssemblyName)</PackageId>
35-
<Version>2.4.1</Version>
35+
<Version>2.5.0</Version>
3636

3737
<!-- Title, Description, Tags -->
3838
<Title>$(AssemblyName)</Title>
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#if NOT_PUBLISHING_PACKAGE
2+
using System;
3+
using System.Collections.Generic;
4+
using System.Runtime.CompilerServices;
5+
6+
namespace Chasm.Compatibility
7+
{
8+
// A compilation-time test to ensure that the polyfilled API is available here
9+
internal class Test
10+
{
11+
public required int Number;
12+
13+
public static void Run(ref readonly string t)
14+
{
15+
List<int> numbers = [0, 1, 2, 3, 4, 5, t.Length];
16+
17+
byte[] buffer = [0, 0, 1, 2];
18+
int int32 = Unsafe.As<byte, int>(ref buffer[0]);
19+
20+
(string Name, int A) tuple = ("two", 2);
21+
22+
int num = numbers[^tuple.A];
23+
24+
_ = HashCode.Combine(int32, tuple, num);
25+
}
26+
}
27+
}
28+
#endif

Chasm.sln.DotSettings

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
22
<s:Boolean x:Key="/Default/UserDictionary/Words/=Formattable/@EntryIndexedValue">True</s:Boolean>
3+
<s:Boolean x:Key="/Default/UserDictionary/Words/=polyfilled/@EntryIndexedValue">True</s:Boolean>
34
<s:Boolean x:Key="/Default/UserDictionary/Words/=resugar/@EntryIndexedValue">True</s:Boolean>
45
<s:Boolean x:Key="/Default/UserDictionary/Words/=resugared/@EntryIndexedValue">True</s:Boolean>
56
<s:Boolean x:Key="/Default/UserDictionary/Words/=resugarable/@EntryIndexedValue">True</s:Boolean>

0 commit comments

Comments
 (0)