Skip to content

Commit

Permalink
Adding in TODO note
Browse files Browse the repository at this point in the history
  • Loading branch information
Pauan committed Jun 24, 2019
1 parent 5e88b1e commit bc3ab0b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions crates/js-sys/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4596,6 +4596,8 @@ macro_rules! arrays {
// TODO if this was written in JS it could avoid passing the `view` TypedArray to Rust,
// which would be more efficient

// TODO measure if it's faster to use `slice` instead of `new`

// This is safe because the `new` function makes a copy if its argument is a TypedArray
unsafe { $name::new(&$name::view(slice)) }
}
Expand Down

0 comments on commit bc3ab0b

Please sign in to comment.