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

Use unsigned_abs() in max_weight_matching #609

Closed
wants to merge 2 commits into from

Conversation

mtreinish
Copy link
Member

In the upcoming Rust 1.61.0 release a new clipply lint warning is being
added to cargo clippy. This will be matched on any output from .abs()
calls that immediately cast to an unsigned type [1]. This was being done
in the max weight matching function in retworkx and will cause errors
when 1.61.0 is released. To address this issue from coming up this
commit switches the use of .abs() to .unsigned_abs().

[1] https://rust-lang.github.io/rust-clippy/master/index.html#cast_abs_to_unsigned

In the upcoming Rust 1.61.0 release a new clipply lint warning is being
added to cargo clippy. This will be matched on any output from .abs()
calls that immediately cast to an unsigned type [1]. This was being done
in the max weight matching function in retworkx and will cause errors
when 1.61.0 is released. To address this issue from coming up this
commit switches the use of .abs() to .unsigned_abs().

[1] https://rust-lang.github.io/rust-clippy/master/index.html#cast_abs_to_unsigned
@mtreinish
Copy link
Member Author

Oh, I guess it wasn't stabilized in 1.48 I'm just going to close this. We'll just have to disable the clippy rule after 1.61 is released I guess since we can't use unsigned_abs() with our MSRV.

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

Successfully merging this pull request may close these issues.

1 participant