Skip to content

Commit 75af01b

Browse files
committed
Fix ambiguous precedences in tests
1 parent 0a3188b commit 75af01b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tests/rustdoc/const-generics/const-generics-docs.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ pub async fn b_sink<const N: usize>(_: impl Trait<N>) {}
7474

7575
// @has foo/fn.concrete.html '//pre[@class="rust item-decl"]' \
7676
// 'pub fn concrete() -> [u8; 22]'
77-
pub fn concrete() -> [u8; 3 + std::mem::size_of::<u64>() << 1] {
77+
pub fn concrete() -> [u8; (3 + std::mem::size_of::<u64>()) << 1] {
7878
Default::default()
7979
}
8080

tests/ui/consts/const-err-rpass.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const W: bool = Z <= 'B';
99

1010

1111
fn main() {
12-
let _ = ((-1 as i8) << 8 - 1) as f32;
12+
let _ = ((-1 as i8) << (8 - 1)) as f32;
1313
let _ = 0u8 as char;
1414
let _ = true > false;
1515
let _ = true >= false;

0 commit comments

Comments
 (0)