diff options
| author | yukang <moorekang@gmail.com> | 2023-04-28 09:55:38 +0800 |
|---|---|---|
| committer | yukang <moorekang@gmail.com> | 2023-05-01 16:37:00 +0800 |
| commit | 5d1796a608d387be784f17c28ec7c81f178a81eb (patch) | |
| tree | 5a5aaafdd30a1c51393aa9d3215b048269089a81 /compiler/rustc_builtin_macros/src | |
| parent | 0fe1ff2137f75ff5fafd45c04558c5f8ce9a00ee (diff) | |
| download | rust-5d1796a608d387be784f17c28ec7c81f178a81eb.tar.gz rust-5d1796a608d387be784f17c28ec7c81f178a81eb.zip | |
soften the wording for removing type ascription
Diffstat (limited to 'compiler/rustc_builtin_macros/src')
| -rw-r--r-- | compiler/rustc_builtin_macros/src/asm.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/compiler/rustc_builtin_macros/src/asm.rs b/compiler/rustc_builtin_macros/src/asm.rs index 3ccdc8179a5..0ea8454db08 100644 --- a/compiler/rustc_builtin_macros/src/asm.rs +++ b/compiler/rustc_builtin_macros/src/asm.rs @@ -68,8 +68,7 @@ pub fn parse_asm_args<'a>( if !p.eat(&token::Comma) { if allow_templates { // After a template string, we always expect *only* a comma... - let mut err = diag.create_err(errors::AsmExpectedComma { span: p.token.span }); - return Err(err); + return Err(diag.create_err(errors::AsmExpectedComma { span: p.token.span })); } else { // ...after that delegate to `expect` to also include the other expected tokens. return Err(p.expect(&token::Comma).err().unwrap()); |
