Compile error from missing wide traits.
mohaque0 opened this issue · 3 comments
mohaque0 commented
Hi. I get a number of compile errors when attempting to run cargo build
and also when attempting to use ultraviolet as a dependency in a project. All of the errors look similar.
Here is an example error:
error[E0599]: no method named `cmp_ge` found for struct `wide::f32x4` in the current scope
--> src/util.rs:32:19
|
32 | r.cmp_ge(eps).none()
| ^^^^^^ method not found in `wide::f32x4`
...
38 | impl_eq_eps_wide!(f32x4, f32x8, f64x2, f64x4);
| ---------------------------------------------- in this macro invocation
|
= help: items from traits can only be used if the trait is in scope
= note: the following trait is implemented but not in scope; perhaps add a `use` for it:
`use wide::CmpGe;`
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
I'm able to fix them by applying the following diff:
diff --git a/src/lib.rs b/src/lib.rs
index 8f37eba..fe000f2 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -120,6 +120,7 @@ pub use transform::*;
pub use vec::*;
pub(crate) use wide;
+use wide::*;
pub use wide::f32x4;
pub use wide::f32x8;
Was that statement missing or am I doing something wrong somewhere?
fu5ha commented
Hm. It seems like you might have just gotten unlucky and are somehow being given a yanked version of wide
(looks like they released a semver breaking change as a patch version but have already yanked it...
try a cargo update
and see if it'll fetch a non broken version
mohaque0 commented
That worked! It's compiling just fine now. Thanks for helping!
fu5ha commented
Great, closing this then :)