-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Improve error message when _ is used for in/inout asm operands #88209
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
(rust-highfive has picked a reviewer for you, use r? to override) |
r? @nagisa |
This seems like a more general problem plaguing
cc @estebank might be of interest to you. Overall this seems like a good place to provide @bors r+ |
📌 Commit 4d6bfde has been approved by |
🌲 The tree is currently closed for pull requests below priority 100. This pull request will be tested once the tree is reopened. |
Ah well, another thing that would be nice is some deduplication. I would perhaps extract if p.eat_keyword(kw::Underscore) {
let err = ecx.struct_span_err(p.token.span, "_ cannot be used for input operands");
return Err(err);
}
let expr = p.parse_expr()?; into a |
@nagisa weird rust/compiler/rustc_parse/src/parser/expr.rs Lines 1182 to 1184 in 77ac329
|
Improve error message when _ is used for in/inout asm operands As suggested by `@Commeownist` in rust-lang#72016 (comment).
Improve error message when _ is used for in/inout asm operands As suggested by ``@Commeownist`` in rust-lang#72016 (comment).
…ingjubilee Rollup of 10 pull requests Successful merges: - rust-lang#87904 (Reword description of automatic impls of `Unsize`.) - rust-lang#88147 (Fix non-capturing closure return type coercion) - rust-lang#88209 (Improve error message when _ is used for in/inout asm operands) - rust-lang#88668 (Change more x64 size checks to not apply to x32.) - rust-lang#88733 (Fix ICE for functions with more than 65535 arguments) - rust-lang#88757 (Suggest wapping expr in parentheses on invalid unary negation) - rust-lang#88779 (Use more accurate spans for "unused delimiter" lint) - rust-lang#88830 (Add help for E0463) - rust-lang#88849 (don't clone types that are Copy (clippy::clone_on_copy)) - rust-lang#88850 (don't convert types into identical types) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
As suggested by @Commeownist in #72016 (comment).