Skip to content

[DEAD] Improve Window, WindowLeft and WindowRight - #10

Closed
Orace wants to merge 2 commits into
atifaziz:masterfrom
Orace:ImproveWindow
Closed

[DEAD] Improve Window, WindowLeft and WindowRight#10
Orace wants to merge 2 commits into
atifaziz:masterfrom
Orace:ImproveWindow

Conversation

@Orace

@Orace Orace commented Oct 31, 2019

Copy link
Copy Markdown

The branch is here to fix morelinq#627.

Window, WindowLeft and WindowRight take O(sourceSize*windowSize) in memory.
If we accept that the method returns IEnumerable<IReadOnlyList<TSource>> instead of IEnumerable<IList<TSource>>, we can go down to O(consumedElement) < O(sourceSize).

@Orace Orace changed the title Fix #627 Improve Window, WindowLeft and WindowRight Oct 31, 2019
@atifaziz

Copy link
Copy Markdown
Owner

Could you please submit this PR on the main project/repo for reasons laid out in my comment on PR #8? Closing it here meanwhile.

Thanks!

@atifaziz atifaziz closed this Oct 31, 2019
@Orace

Orace commented Nov 6, 2019

Copy link
Copy Markdown
Author

Window are writable by design.

@Orace Orace changed the title Improve Window, WindowLeft and WindowRight [DEAD] Improve Window, WindowLeft and WindowRight Nov 6, 2019
@Orace
Orace deleted the ImproveWindow branch November 6, 2019 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Window, WindowLeft and WindowRight are not optimal in memory

2 participants