Skip to content

Bound error on ParallelFor conversion #72

@fredericDelaporte

Description

@fredericDelaporte

ParallelFor(1, 100, ...) is converted to Task.WhenAll(Enumerable.Range(1, 100)... while it should be Task.WhenAll(Enumerable.Range(1, 99). (#63)

ParallelFor semantic is "first included last excluded", while Range semantic is "first included, total count".
So if we have ParallelFor(a, b, ...), the conversion should yield Task.WhenAll(Enumerable.Range(a, b - a)....

This was spotted with nhibernate/nhibernate-core#1455 test.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions