Skip to content

Commit

Permalink
Add test for #75158
Browse files Browse the repository at this point in the history
Closes #75158
  • Loading branch information
osa1 committed Feb 5, 2021
1 parent 6a388dc commit b46fe85
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/test/ui/issues/issue-75158-64.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
//~ ERROR

// build-fail
// ignore-32bit

struct S<T> {
x: [T; !0],
}

pub fn f() -> usize {
std::mem::size_of::<S<u8>>()
}

fn main() {
let x = f();
}
4 changes: 4 additions & 0 deletions src/test/ui/issues/issue-75158-64.stderr
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
error: values of the type `[u8; 18446744073709551615]` are too big for the current architecture

error: aborting due to previous error

0 comments on commit b46fe85

Please sign in to comment.