rustgd / cgmath

A linear algebra and mathematics library for computer graphics.
https://docs.rs/cgmath
Apache License 2.0
1.13k stars 155 forks source link

Use transmute_copy for into impl #437

Closed Xaeroxe closed 6 years ago

Xaeroxe commented 7 years ago

Fixes https://github.com/brendanzab/cgmath/issues/436

So while this isn't a perfect no-op like I hoped for it's still a slight improvement over what was present. A transmute without _copy wasn't possible because even though it is possible to prove Vector3\<S> is the same size as [S; 3] rustc just isn't that smart yet. So this is the next best thing.

brendanzab commented 7 years ago

Seem to have a build failure 🤔

Xaeroxe commented 6 years ago

I'm not really certain this is that much of an improvement over what's already here so I'll close it