-
-
Notifications
You must be signed in to change notification settings - Fork 48
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
Initial work on a Vector
trait
#153
base: master
Are you sure you want to change the base?
Conversation
e48a6d3
to
daf1b44
Compare
Looks great to me! I'm not personally a user of this crate, so maybe try to check around you or in the community what they think about it? |
Added benefits to the additional generality: - all functions are bound checked; - the complex numbers are handled correctly and are compatible with their standard Rust representation.
As this trait will be requested to be brought into scope to set strides, it is good that the functions required to define its capabilities do not conflict with methods that the type may originally have.
The code now triggers lots of “transmute used without annotations” which are unrelated to my changes. There is still quite a bit of work to do (there are still |
Can you use stride crate instead of Slice/SliceMut? |
@hugohp Not sure what you have in mind since, here, the strides need not be const — |
As discussed in #147, here is some preliminary work on the introduction of a
Vector
trait (forfit
andcblas::level1
). (It is better to have early feedback before doing more work! In particular aStride
trait must be developed to be able to add strides to anyVector
container.)Note that, as added benefits, the equality of lengths of inputs is now checked (no way of specifying a longer length than allocated) and complex numbers are handled correctly (and in a compatible way with their Rust standard representation).