Skip to content

Conversation

LinusU
Copy link
Contributor

@LinusU LinusU commented Nov 8, 2018

It seems like the end argument was treated as the length in the subarray function.

This was part of the test before:

arr = arr.subarray(1, 2);
assert(arr.length == 1);
assert(arr.byteOffset == 1 * sizeof<i32>());
assert(arr.byteLength == 2 * sizeof<i32>());

But the byteLength should be equal to arr.length * sizeof<i32>(), right?

The tests are still failing though so need to investigate more when I have time, opening for visibility...

@MaxGraey
Copy link
Member

MaxGraey commented Nov 8, 2018

Thank you for paying attention to this. This has been fixed in #328

@LinusU LinusU closed this Nov 9, 2018
@LinusU LinusU deleted the subarray branch November 9, 2018 10:57
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.

2 participants