Skip to content

Commit da9d4b0

Browse files
committed
Remove the experimental attribute from the tensor APIs
1 parent a5d7490 commit da9d4b0

17 files changed

+0
-32
lines changed

src/libraries/System.Numerics.Tensors/ref/System.Numerics.Tensors.csproj

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
<PropertyGroup>
44
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppPrevious);$(NetCoreAppMinimum);netstandard2.0;$(NetFrameworkMinimum)</TargetFrameworks>
55
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
6-
<!-- SYSLIB5001: Tensor<T> and related APIs in System.Numerics.Tensors are experimental in .NET 9 -->
7-
<NoWarn>$(NoWarn);SYSLIB5001</NoWarn>
86
</PropertyGroup>
97

108
<ItemGroup>

src/libraries/System.Numerics.Tensors/ref/System.Numerics.Tensors.netcore.cs

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
namespace System.Buffers
88
{
9-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
109
public readonly partial struct NIndex : System.IEquatable<System.Buffers.NIndex>
1110
{
1211
private readonly int _dummyPrimitive;
@@ -30,7 +29,6 @@ namespace System.Buffers
3029
public System.Index ToIndexUnchecked() { throw null; }
3130
public override string ToString() { throw null; }
3231
}
33-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
3432
public readonly partial struct NRange : System.IEquatable<System.Buffers.NRange>
3533
{
3634
private readonly int _dummyPrimitive;
@@ -55,7 +53,6 @@ namespace System.Buffers
5553
}
5654
namespace System.Numerics.Tensors
5755
{
58-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
5956
public partial interface IReadOnlyTensor
6057
{
6158
nint FlattenedLength { get; }
@@ -72,7 +69,6 @@ public partial interface IReadOnlyTensor
7269
System.ReadOnlySpan<nint> Strides { get; }
7370
System.Buffers.MemoryHandle GetPinnedHandle();
7471
}
75-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
7672
public partial interface IReadOnlyTensor<TSelf, T> : System.Collections.Generic.IEnumerable<T>, System.Collections.IEnumerable, System.Numerics.Tensors.IReadOnlyTensor where TSelf : System.Numerics.Tensors.IReadOnlyTensor<TSelf, T>
7773
{
7874
static abstract TSelf Empty { get; }
@@ -94,7 +90,6 @@ public partial interface IReadOnlyTensor<TSelf, T> : System.Collections.Generic.
9490
bool TryCopyTo(scoped in System.Numerics.Tensors.TensorSpan<T> destination);
9591
bool TryFlattenTo(scoped System.Span<T> destination);
9692
}
97-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
9893
public partial interface ITensor : System.Numerics.Tensors.IReadOnlyTensor
9994
{
10095
bool IsReadOnly { get; }
@@ -103,7 +98,6 @@ public partial interface ITensor : System.Numerics.Tensors.IReadOnlyTensor
10398
void Clear();
10499
void Fill(object value);
105100
}
106-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
107101
public partial interface ITensor<TSelf, T> : System.Collections.Generic.IEnumerable<T>, System.Collections.IEnumerable, System.Numerics.Tensors.IReadOnlyTensor, System.Numerics.Tensors.IReadOnlyTensor<TSelf, T>, System.Numerics.Tensors.ITensor where TSelf : System.Numerics.Tensors.ITensor<TSelf, T>
108102
{
109103
new ref T this[params scoped System.ReadOnlySpan<System.Buffers.NIndex> indexes] { get; }
@@ -137,7 +131,6 @@ public ref partial struct Enumerator
137131
public void Reset() { }
138132
}
139133
}
140-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
141134
public readonly ref partial struct ReadOnlyTensorSpan<T>
142135
{
143136
private readonly object _dummy;
@@ -208,7 +201,6 @@ public void Reset() { }
208201
void System.IDisposable.Dispose() { }
209202
}
210203
}
211-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
212204
public static partial class Tensor
213205
{
214206
public static System.Numerics.Tensors.Tensor<T> Abs<T>(in System.Numerics.Tensors.ReadOnlyTensorSpan<T> x) where T : System.Numerics.INumberBase<T> { throw null; }
@@ -823,7 +815,6 @@ public static void Truncate<T>(System.ReadOnlySpan<T> x, System.Span<T> destinat
823815
public static void Xor<T>(System.ReadOnlySpan<T> x, System.ReadOnlySpan<T> y, System.Span<T> destination) where T : System.Numerics.IBitwiseOperators<T, T, T> { }
824816
public static void Xor<T>(System.ReadOnlySpan<T> x, T y, System.Span<T> destination) where T : System.Numerics.IBitwiseOperators<T, T, T> { }
825817
}
826-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
827818
public readonly ref partial struct TensorSpan<T>
828819
{
829820
private readonly object _dummy;
@@ -900,7 +891,6 @@ public void Reset() { }
900891
void System.IDisposable.Dispose() { }
901892
}
902893
}
903-
[System.Diagnostics.CodeAnalysis.ExperimentalAttribute("SYSLIB5001", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
904894
public sealed partial class Tensor<T> : System.Collections.Generic.IEnumerable<T>, System.Collections.IEnumerable, System.Numerics.Tensors.IReadOnlyTensor, System.Numerics.Tensors.IReadOnlyTensor<System.Numerics.Tensors.Tensor<T>, T>, System.Numerics.Tensors.ITensor, System.Numerics.Tensors.ITensor<System.Numerics.Tensors.Tensor<T>, T>
905895
{
906896
internal Tensor() { }

src/libraries/System.Numerics.Tensors/src/System.Numerics.Tensors.csproj

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,13 @@
77
<PackageDescription>Provides support for operating over tensors.</PackageDescription>
88
<GenAPIExcludeApiList>ReferenceAssemblyExclusions.txt</GenAPIExcludeApiList>
99
<GenAPITargetPath>$([MSBuild]::NormalizePath('$(MSBuildProjectDirectory)', '..', 'ref', '$(AssemblyName).netcore.cs'))</GenAPITargetPath>
10-
<!-- SYSLIB5001: Tensor<T> and related APIs in System.Numerics.Tensors are experimental in .NET 9 -->
11-
<NoWarn>$(NoWarn);SYSLIB5001</NoWarn>
1210
</PropertyGroup>
1311

1412
<ItemGroup>
1513
<Compile Include="Properties\InternalVisibleTo.cs" />
1614
<Compile Include="System\Numerics\Tensors\TensorPrimitives.Single.cs" />
1715
<Compile Include="System\Numerics\Tensors\TensorPrimitives.Helpers.cs" />
1816
<Compile Include="System\ThrowHelper.cs" />
19-
<Compile Include="$(CommonPath)System\Experimentals.cs" Link="Common\System\Experimentals.cs" />
2017
</ItemGroup>
2118

2219
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETCoreApp'">

src/libraries/System.Numerics.Tensors/src/System/Buffers/NIndex.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ namespace System.Buffers
1414
/// int lastElement = someArray[^1]; // lastElement = 5
1515
/// </code>
1616
/// </remarks>
17-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
1817
public readonly struct NIndex : IEquatable<NIndex>
1918
{
2019
private readonly nint _value;

src/libraries/System.Numerics.Tensors/src/System/Buffers/NRange.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ namespace System.Buffers
1515
/// int[] subArray2 = someArray[1..^0]; // { 2, 3, 4, 5 }
1616
/// </code>
1717
/// </remarks>
18-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
1918
public readonly struct NRange : IEquatable<NRange>
2019
{
2120
/// <summary>Gets the inclusive start NIndex of the NRange.</summary>

src/libraries/System.Numerics.Tensors/src/System/Numerics/Tensors/netcore/IReadOnlyTensor.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
namespace System.Numerics.Tensors
88
{
99
/// <summary>Represents a read-only tensor.</summary>
10-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
1110
public interface IReadOnlyTensor
1211
{
1312
/// <summary>Gets the specified element of the tensor.</summary>

src/libraries/System.Numerics.Tensors/src/System/Numerics/Tensors/netcore/IReadOnlyTensor_1.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ namespace System.Numerics.Tensors
1010
/// <summary>Represents a read-only tensor.</summary>
1111
/// <typeparam name="TSelf">The type that implements this interface.</typeparam>
1212
/// <typeparam name="T">The element type.</typeparam>
13-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
1413
public interface IReadOnlyTensor<TSelf, T> : IReadOnlyTensor, IEnumerable<T>
1514
where TSelf : IReadOnlyTensor<TSelf, T>
1615
{

src/libraries/System.Numerics.Tensors/src/System/Numerics/Tensors/netcore/ITensor.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
namespace System.Numerics.Tensors
88
{
99
/// <summary>Represents a tensor.</summary>
10-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
1110
public interface ITensor : IReadOnlyTensor
1211
{
1312
/// <summary>Gets or sets the specified element of the tensor.</summary>

src/libraries/System.Numerics.Tensors/src/System/Numerics/Tensors/netcore/ITensor_1.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ namespace System.Numerics.Tensors
99
/// <summary>Represents a tensor.</summary>
1010
/// <typeparam name="TSelf">The type that implements this interface.</typeparam>
1111
/// <typeparam name="T">The element type.</typeparam>
12-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
1312
public interface ITensor<TSelf, T> : ITensor, IReadOnlyTensor<TSelf, T>
1413
where TSelf : ITensor<TSelf, T>
1514
{

src/libraries/System.Numerics.Tensors/src/System/Numerics/Tensors/netcore/ReadOnlyTensorSpan_1.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ namespace System.Numerics.Tensors
2121
/// <typeparam name="T">The type of the elements within the tensor span.</typeparam>
2222
[DebuggerTypeProxy(typeof(TensorSpanDebugView<>))]
2323
[DebuggerDisplay("{ToString(),raw}")]
24-
[Experimental(Experimentals.TensorTDiagId, UrlFormat = Experimentals.SharedUrlFormat)]
2524
public readonly ref struct ReadOnlyTensorSpan<T>
2625
{
2726
/// <inheritdoc cref="IReadOnlyTensor{TSelf, T}.Empty" />

0 commit comments

Comments
 (0)