"Unnecessary" braces have an influence #72783
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
C-enhancement
Category: An issue proposing an enhancement or a PR with one.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
On
1.45.0-nightly (2020-05-29 4bd32c98047a809ba5fd)
Intuitively, I would expect these braces to be redundant and also have no influence, but they do. The compiler expects a
()
type and then considers the minus sign a unary operator.It seems to me that either the error message about the braces being redundant is incorrect or misleading, or something more nefarious seems to be going on with scopes, expressions, etc.
The text was updated successfully, but these errors were encountered: