Skip to content

Commit 0e6c53c

Browse files
committed
Name the portions of the ValueTuple
1 parent 1b18f0b commit 0e6c53c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

CSparse/Converter.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,14 +297,14 @@ public static CoordinateStorage<T> FromEnumerable<T>(IEnumerable<Tuple<int, int,
297297
/// <param name="rowCount">Number of rows.</param>
298298
/// <param name="columnCount">Number of columns.</param>
299299
/// <returns>Coordinate storage.</returns>
300-
public static CoordinateStorage<T> FromEnumerable<T>(IEnumerable<(int, int, T)> enumerable, int rowCount, int columnCount)
300+
public static CoordinateStorage<T> FromEnumerable<T>(IEnumerable<(int row, int column, T value)> enumerable, int rowCount, int columnCount)
301301
where T : struct, IEquatable<T>, IFormattable
302302
{
303303
var storage = new CoordinateStorage<T>(rowCount, columnCount, Math.Max(rowCount, columnCount));
304304

305305
foreach (var item in enumerable)
306306
{
307-
storage.At(item.Item1, item.Item2, item.Item3);
307+
storage.At(item.row, item.column, item.value);
308308
}
309309

310310
return storage;

CSparse/Storage/CompressedColumnStorage.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ public static CompressedColumnStorage<T> OfIndexed(int rows, int columns, IEnume
156156
/// <summary>
157157
/// Create a new sparse matrix as a copy of the given indexed enumerable using a value tuple.
158158
/// </summary>
159-
public static CompressedColumnStorage<T> OfIndexed(int rows, int columns, IEnumerable<(int, int, T)> enumerable)
159+
public static CompressedColumnStorage<T> OfIndexed(int rows, int columns, IEnumerable<(int row, int column, T value)> enumerable)
160160
{
161161
var c = Converter.FromEnumerable<T>(enumerable, rows, columns);
162162

0 commit comments

Comments
 (0)