Add method to convert a Matrix into a Vec.
Open
enhancement
good first issue
P-medium
- Dominant language
- Rust
- Stars
- 4.8k
- Forks
- 565
- PR merge metrics
- No merged PRs in 30d
Description
See https://github.com/rustsim/nalgebra/issues/473#issuecomment-440038489
The goal is to add an `.into_vec` method that would either unwrap the underlying `Vec` storage, or would perform a copy if the storage is not `MatrixVec`.
Note that one way of achieving this would be to add an implementation of `IntoIter` for `Matrix`. Then the `matrix.into_iter().collect()` will do the trick and will not perform any copy for matrices with a `MatrixVec` storage because of [that optimization](https://github.com/rust-lang/rust/issues/46084#issuecomment-345524508).
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.