Skip to content

Commit 6fff80d

Browse files
committed
Fix ImmutableArrayBuilder<T>.Count reported value
1 parent 11269e1 commit 6fff80d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/CommunityToolkit.Mvvm.SourceGenerators/Helpers/ImmutableArrayBuilder{T}.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ public Writer()
147147
public int Count
148148
{
149149
[MethodImpl(MethodImplOptions.AggressiveInlining)]
150-
get => this.array!.Length;
150+
get => this.index;
151151
}
152152

153153
/// <inheritdoc cref="ImmutableArrayBuilder{T}.WrittenSpan"/>

0 commit comments

Comments
 (0)