Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Storage should be implemented as an unsafe trait #39

Closed
vbarrielle opened this issue Dec 16, 2015 · 3 comments
Closed

Storage should be implemented as an unsafe trait #39

vbarrielle opened this issue Dec 16, 2015 · 3 comments
Assignees

Comments

@vbarrielle
Copy link
Collaborator

See rust-lang/rust#29701
The implementation in bluss/rust-ndarray looks like a good example of how to do it.

@bluss
Copy link

bluss commented Jan 8, 2016

Maybe it doesn't matter if all constructors are locked down?

@vbarrielle
Copy link
Collaborator Author

Maybe indeed. Having a dedicated trait can be beneficial in some cases though.
For instance, a sparse vector can be seen as a sparse matrix, but currently
this is done by creating a sparse matrix with Vec as a backend for the indptr
storage. Having a trait would enable having a [usize; 2] for the indptr.

@vbarrielle vbarrielle self-assigned this Aug 18, 2017
@vbarrielle
Copy link
Collaborator Author

Since the only valid reason was the matrix view around a vector, #111 fixes this issue.

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

No branches or pull requests

2 participants