@@ -55,21 +55,28 @@ namespace System.Buffers
5555}
5656namespace System . Numerics . Tensors
5757{
58- [ System . Diagnostics . CodeAnalysis . Experimental ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
59- public partial interface IReadOnlyTensor < TSelf , T > : System . Collections . Generic . IEnumerable < T > , System . Collections . IEnumerable where TSelf : System . Numerics . Tensors . IReadOnlyTensor < TSelf , T >
58+ [ System . Diagnostics . CodeAnalysis . ExperimentalAttribute ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
59+ public partial interface IReadOnlyTensor
6060 {
61- static abstract TSelf ? Empty { get ; }
6261 nint FlattenedLength { get ; }
6362 bool IsEmpty { get ; }
6463 bool IsPinned { get ; }
65- T this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get ; }
66- TSelf this [ params scoped System. ReadOnlySpan < System . Buffers . NRange > ranges ] { get ; }
67- T this [ params scoped System. ReadOnlySpan < nint > indexes ] { get ; }
64+ object this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get ; }
65+ object this [ params scoped System. ReadOnlySpan < nint > indexes ] { get ; }
6866 [ System . Diagnostics . CodeAnalysis . UnscopedRefAttribute ]
6967 System . ReadOnlySpan < nint > Lengths { get ; }
7068 int Rank { get ; }
7169 [ System . Diagnostics . CodeAnalysis . UnscopedRefAttribute ]
7270 System . ReadOnlySpan < nint > Strides { get ; }
71+ System . Buffers . MemoryHandle GetPinnedHandle ( ) ;
72+ }
73+ [ System . Diagnostics . CodeAnalysis . ExperimentalAttribute ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
74+ 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 >
75+ {
76+ static abstract TSelf ? Empty { get ; }
77+ new T this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get ; }
78+ TSelf this [ params scoped System. ReadOnlySpan < System . Buffers . NRange > ranges ] { get ; }
79+ new T this [ params scoped System. ReadOnlySpan < nint > indexes ] { get ; }
7380 System . Numerics . Tensors . ReadOnlyTensorSpan < T > AsReadOnlyTensorSpan ( ) ;
7481 System . Numerics . Tensors . ReadOnlyTensorSpan < T > AsReadOnlyTensorSpan ( params scoped System. ReadOnlySpan < System . Buffers . NIndex > startIndex ) ;
7582 System . Numerics . Tensors . ReadOnlyTensorSpan < T > AsReadOnlyTensorSpan ( params scoped System. ReadOnlySpan < System . Buffers . NRange > range ) ;
@@ -83,18 +90,25 @@ public partial interface IReadOnlyTensor<TSelf, T> : System.Collections.Generic.
8390 bool TryCopyTo ( scoped System . Numerics . Tensors . TensorSpan < T > destination ) ;
8491 bool TryFlattenTo ( scoped System . Span < T > destination ) ;
8592 }
86- [ System . Diagnostics . CodeAnalysis . Experimental ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
87- public partial interface ITensor < TSelf , T > : System . Collections . Generic . IEnumerable < T > , System . Collections . IEnumerable , System . Numerics . Tensors . IReadOnlyTensor < TSelf , T > where TSelf : System . Numerics . Tensors . ITensor < TSelf , T >
93+ [ System . Diagnostics . CodeAnalysis . ExperimentalAttribute ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
94+ public partial interface ITensor : System . Numerics . Tensors . IReadOnlyTensor
8895 {
8996 bool IsReadOnly { get ; }
97+ new object this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get ; set ; }
98+ new object this [ params scoped System. ReadOnlySpan < nint > indexes ] { get ; set ; }
99+ void Clear ( ) ;
100+ void Fill ( object value ) ;
101+ }
102+ [ System . Diagnostics . CodeAnalysis . ExperimentalAttribute ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
103+ 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 >
104+ {
90105 new T this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get ; set ; }
91106 new TSelf this [ params scoped System. ReadOnlySpan < System . Buffers . NRange > ranges ] { get ; set ; }
92107 new T this [ params scoped System. ReadOnlySpan < nint > indexes ] { get ; set ; }
93108 System . Numerics . Tensors . TensorSpan < T > AsTensorSpan ( ) ;
94109 System . Numerics . Tensors . TensorSpan < T > AsTensorSpan ( params scoped System. ReadOnlySpan < System . Buffers . NIndex > startIndex ) ;
95110 System . Numerics . Tensors . TensorSpan < T > AsTensorSpan ( params scoped System. ReadOnlySpan < System . Buffers . NRange > range ) ;
96111 System . Numerics . Tensors . TensorSpan < T > AsTensorSpan ( params scoped System. ReadOnlySpan < nint > start ) ;
97- void Clear ( ) ;
98112 static abstract TSelf Create ( scoped System . ReadOnlySpan < nint > lengths , bool pinned = false ) ;
99113 static abstract TSelf Create ( scoped System . ReadOnlySpan < nint > lengths , scoped System . ReadOnlySpan < nint > strides , bool pinned = false ) ;
100114 static abstract TSelf CreateUninitialized ( scoped System . ReadOnlySpan < nint > lengths , bool pinned = false ) ;
@@ -816,8 +830,8 @@ public ref partial struct Enumerator
816830 public bool MoveNext ( ) { throw null ; }
817831 }
818832 }
819- [ System . Diagnostics . CodeAnalysis . Experimental ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
820- public sealed partial class Tensor < T > : System . Collections . Generic . IEnumerable < T > , System . Collections . IEnumerable , System . Numerics . Tensors . IReadOnlyTensor < System . Numerics . Tensors . Tensor < T > , T > , System . Numerics . Tensors . ITensor < System . Numerics . Tensors . Tensor < T > , T >
833+ [ System . Diagnostics . CodeAnalysis . ExperimentalAttribute ( "SYSLIB5001" , UrlFormat = "https://aka.ms/dotnet-warnings/{0}" ) ]
834+ 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 >
821835 {
822836 internal Tensor ( ) { }
823837 public static System . Numerics . Tensors . Tensor < T > Empty { get { throw null ; } }
@@ -831,12 +845,16 @@ internal Tensor() { }
831845 public System . ReadOnlySpan < nint > Lengths { get { throw null ; } }
832846 public int Rank { get { throw null ; } }
833847 public System . ReadOnlySpan < nint > Strides { get { throw null ; } }
848+ object System . Numerics . Tensors . IReadOnlyTensor . this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get { throw null ; } }
849+ object System . Numerics . Tensors . IReadOnlyTensor . this [ params scoped System. ReadOnlySpan < nint > indexes ] { get { throw null ; } }
850+ System . ReadOnlySpan < nint > System . Numerics . Tensors . IReadOnlyTensor . Lengths { get { throw null ; } }
851+ System . ReadOnlySpan < nint > System . Numerics . Tensors . IReadOnlyTensor . Strides { get { throw null ; } }
834852 T System . Numerics . Tensors . IReadOnlyTensor < System . Numerics . Tensors . Tensor < T > , T > . this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get { throw null ; } }
835853 System . Numerics . Tensors . Tensor < T > System . Numerics . Tensors . IReadOnlyTensor < System . Numerics . Tensors . Tensor < T > , T > . this [ params scoped System. ReadOnlySpan < System . Buffers . NRange > ranges ] { get { throw null ; } }
836854 T System . Numerics . Tensors . IReadOnlyTensor < System . Numerics . Tensors . Tensor < T > , T > . this [ params scoped System. ReadOnlySpan < nint > indexes ] { get { throw null ; } }
837- System . ReadOnlySpan < nint > System . Numerics . Tensors . IReadOnlyTensor < System . Numerics . Tensors . Tensor < T > , T > . Lengths { get { throw null ; } }
838- System . ReadOnlySpan < nint > System . Numerics . Tensors . IReadOnlyTensor < System . Numerics . Tensors . Tensor < T > , T > . Strides { get { throw null ; } }
839- bool System . Numerics . Tensors . ITensor < System . Numerics . Tensors . Tensor < T > , T > . IsReadOnly { get { throw null ; } }
855+ bool System . Numerics . Tensors . ITensor . IsReadOnly { get { throw null ; } }
856+ object System . Numerics . Tensors . ITensor . this [ params scoped System . ReadOnlySpan < System . Buffers . NIndex > indexes ] { get { throw null ; } set { } }
857+ object System . Numerics . Tensors . ITensor . this [ params scoped System. ReadOnlySpan < nint > indexes ] { get { throw null ; } set { } }
840858 T System . Numerics . Tensors . ITensor < System . Numerics . Tensors . Tensor < T > , T > . this [ params scoped System. ReadOnlySpan < System . Buffers . NIndex > indexes ] { get { throw null ; } set { } }
841859 T System . Numerics . Tensors . ITensor < System . Numerics . Tensors . Tensor < T > , T > . this [ params scoped System. ReadOnlySpan < nint > indexes ] { get { throw null ; } set { } }
842860 public System . Numerics . Tensors . ReadOnlyTensorSpan < T > AsReadOnlyTensorSpan ( ) { throw null ; }
@@ -849,12 +867,14 @@ internal Tensor() { }
849867 public System . Numerics . Tensors . TensorSpan < T > AsTensorSpan ( params scoped System. ReadOnlySpan < nint > start ) { throw null ; }
850868 public void Clear ( ) { }
851869 public void CopyTo ( scoped System . Numerics . Tensors . TensorSpan < T > destination ) { }
870+ public void Fill ( object value ) { }
852871 public void Fill ( T value ) { }
853872 public void FlattenTo ( scoped System . Span < T > destination ) { }
854873 public System . Collections . Generic . IEnumerator < T > GetEnumerator ( ) { throw null ; }
855874 public override int GetHashCode ( ) { throw null ; }
856875 [ System . ComponentModel . EditorBrowsableAttribute ( System . ComponentModel . EditorBrowsableState . Never ) ]
857876 public ref T GetPinnableReference ( ) { throw null ; }
877+ public System . Buffers . MemoryHandle GetPinnedHandle ( ) { throw null ; }
858878 public static implicit operator System . Numerics . Tensors . ReadOnlyTensorSpan < T > ( System . Numerics . Tensors . Tensor < T > value ) { throw null ; }
859879 public static implicit operator System . Numerics . Tensors . TensorSpan < T > ( System . Numerics . Tensors . Tensor < T > value ) { throw null ; }
860880 public static implicit operator System . Numerics . Tensors . Tensor < T > ( T [ ] array ) { throw null ; }
0 commit comments