diff --git a/tests/source/attrib.rs b/tests/source/attrib.rs index d45fba55224..fc13cd02b03 100644 --- a/tests/source/attrib.rs +++ b/tests/source/attrib.rs @@ -214,8 +214,8 @@ pub struct Params { // #3313 fn stmt_expr_attributes() { let foo ; - #[must_use] - foo = false ; + (#[must_use] + foo) = false ; } // #3509 diff --git a/tests/target/attrib.rs b/tests/target/attrib.rs index 7e61f68d76a..7b3309676de 100644 --- a/tests/target/attrib.rs +++ b/tests/target/attrib.rs @@ -248,8 +248,8 @@ pub struct Params { // #3313 fn stmt_expr_attributes() { let foo; - #[must_use] - foo = false; + (#[must_use] + foo) = false; } // #3509