Need help compiling this crate #30
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
mikedilger/float-cmp#30
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I cannot compile this crate. I am depending on it through https://crates.io/crates/mockall and building using https://bazel.build/ with https://github.com/google/cargo-raze. The commit is
github.com/dayfine/xlab@9f9bf1ea41.The error I see is:
I know this is https://github.com/rust-lang/rust/issues/50145, and I also saw https://github.com/mikedilger/float-cmp/issues/25. I am not familiar with
no_stdso I am not sure what's the right thing to do, e.g.:num_traits. Do I wantnum_traitsor not?stdfeature? I don't think I've actually been able to do thatCurrently I might need to not using
mockalland this crate, but I suppose there might be an easy fix that I cannot find.If you enable the 'ratio' feature it will pull in
num_traitswhich defines.abs()in theFloatCoretrait which will get pulled in.If you were using the standard library (vast majority of cases), then
std::f32would have already defined.abs()I suppose since this issue has come up yet again I suppose I could include
abs()functions in the crate (copied from somewhere else so I don't muck it up). But don't expect that I'm pretty busy right now. If usingratiofeature doesn't work, let me know.