Skip to content

Commit 877c2ee

Browse files
Nigel-Ecmajskeet
authored andcommitted
Update standard-library.md
Add indexer and Length properties to Span & ReadOnlySpan
1 parent 1b2b70b commit 877c2ee

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

standard/standard-library.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -558,12 +558,13 @@ namespace System
558558
{
559559
public ref struct ReadOnlySpan<T>
560560
{
561+
public int Length { get; }
562+
public ref readonly T this[int index] { get; }
561563
}
562-
}
563-
namespace System
564-
{
565564
public ref struct Span<T>
566565
{
566+
public int Length { get; }
567+
public ref T this[int index] { get; }
567568
public static implicit operator ReadOnlySpan<T>(Span<T> span);
568569
}
569570
}

0 commit comments

Comments
 (0)