Skip to content

Commit

Permalink
Add test of raw addr expression syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Nov 1, 2024
1 parent 6c52daa commit 7d1a8f9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/test_ensure.rs
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,12 @@ fn test_unary() {

let test = || Ok(ensure!(&mut x == *&&mut &2));
assert_err(test, "Condition failed: `&mut x == *&&mut &2` (1 vs 2)");

let test = || Ok(ensure!(S + &raw const x != S + &raw mut x));
assert_err(
test,
"Condition failed: `S + &raw const x != S + &raw mut x`", // FIXME
);
}

#[test]
Expand Down

0 comments on commit 7d1a8f9

Please sign in to comment.