add #[must_use] macros for floats#154979
Conversation
|
r? @scottmcm rustbot has assigned @scottmcm. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
You haven't added it to all the functions in the issue. |
|
I checked f16-32-64-128 in core/num/ and in std/num and see that must_use is added in all funcs. |
Look at the original issue? |
|
I read it, do you mean i didn't add a description? Or do you mean that i missed some functions for float in other modules rs? |
I mentioned 13 functions, you only added to it 4? |
|
Oh, that's what you're talking about. Well, those attributes were already there, you can check. |
|
for example rust/library/core/src/num/f32.rs Lines 599 to 605 in b6100cc |
|
@ArtemIsmagilov I am so sorry, I had a bug in my code that found the functions without the Looks good. |
|
@rustbot reroll |
|
Can you add a message to these? @rustbot author |
|
Reminder, once the PR becomes ready for a review, use |
add msg
81540b1 to
607021c
Compare
|
I didn't write the message for |
|
That's fine, as it's much clearer when it already returns a different type. @bors r+ rollup |
…jhpratt add #[must_use] macros for floats try resolve rust-lang#154854
Rollup of 10 pull requests Successful merges: - #155370 (Add regression test for dead code elimination with drop + panic) - #154823 (Replace the spdx-rs dependency with a minimal in-tree SPDX tag-value parser) - #155294 (Add test for coalescing of diagnostic attribute duplicates) - #155352 (triagebot.toml: Sync `assign.owners` with `autolabel."T-compiler"`) - #155431 (Add temporary scope to assert_matches) - #152995 (ACP Implementation of PermissionsExt for Windows ) - #153873 (deprecate `std::char` constants and functions) - #154865 (libtest: use binary search for --exact test filtering) - #154979 (add #[must_use] macros for floats) - #155504 (Remove `AttributeLintKind` variants - part 2)
…uwer Rollup of 12 pull requests Successful merges: - #155370 (Add regression test for dead code elimination with drop + panic) - #154823 (Replace the spdx-rs dependency with a minimal in-tree SPDX tag-value parser) - #155294 (Add test for coalescing of diagnostic attribute duplicates) - #155352 (triagebot.toml: Sync `assign.owners` with `autolabel."T-compiler"`) - #155431 (Add temporary scope to assert_matches) - #153873 (deprecate `std::char` constants and functions) - #154865 (libtest: use binary search for --exact test filtering) - #154979 (add #[must_use] macros for floats) - #155486 (c-variadic: add roundtrip test) - #155504 (Remove `AttributeLintKind` variants - part 2) - #155510 (Update Tidy python executable path) - #155514 (codegen-options docs: remove -Csoft-float)
try resolve #154854