Is "must_use" really needed for Option::insert ? #130594
Labels
C-discussion
Category: Discussion or questions that doesn't represent real issues.
T-lang
Relevant to the language team, which will review and decide on the PR/issue.
T-libs-api
Relevant to the library API team, which will review and decide on the PR/issue.
Related to #87196
I personally think
insert
is a more succinct and readable way than= Some(x)
and this seems should be a style preference and don't get why it's marked asmust_use
.what's more weird is
Option::replace
is not marked asmust use
, so the syntax is kind of inconsistent to me.The text was updated successfully, but these errors were encountered: