Skip to content

Windows of Window(Left|Right) are not isolated from each other #652

@Orace

Description

@Orace

List returned by Window* methods should be isolated from each other.

With current implementation, modifying one window will modify the next windows accordingly:

var sequence = Enumerable.Repeat(0, 3);
foreach (var window in sequence.Window(2))
{
  window[1] = 1; // modify the last element

  // on second iteration window[0] is 1 and this fail
  Assert.That(window[0], Is.EqualTo(0));
}

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions