Skip to content

Commit cdcecc8

Browse files
committed
fix error message for #[custom_mir]
1 parent 362e0f9 commit cdcecc8

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

compiler/rustc_attr_parsing/src/attributes/prototype.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ fn extract_value<S: Stage>(
8282
}
8383

8484
let Some(val) = arg.name_value() else {
85-
cx.adcx().expected_single_argument(arg.span().unwrap_or(span), 2);
85+
cx.adcx().expected_name_value(span, Some(key));
8686
*failed = true;
8787
return;
8888
};

0 commit comments

Comments
 (0)