Skip to content

Commit

Permalink
Try again, this time with both 64 and 32 bit ignores.
Browse files Browse the repository at this point in the history
  • Loading branch information
hameerabbasi committed Mar 31, 2021
1 parent 38b3169 commit 38f3c3b
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 8 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0080]: it is undefined behavior to use this value
--> $DIR/union-const-eval-field.rs:29:5
--> $DIR/union-const-eval-field.rs:31:5
|
LL | const FIELD3: Field3 = unsafe { UNION.field3 };
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered uninitialized bytes, but expected initialized plain (non-pointer) bytes
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0080]: it is undefined behavior to use this value
--> $DIR/union-const-eval-field.rs:29:5
--> $DIR/union-const-eval-field.rs:31:5
|
LL | const FIELD3: Field3 = unsafe { UNION.field3 };
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered uninitialized bytes, but expected initialized plain (non-pointer) bytes
Expand Down
2 changes: 2 additions & 0 deletions src/test/ui/consts/const-eval/union-const-eval-field.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// stderr-per-bitwidth
// ignore-wasm32
// ignore-wasm64
#![feature(const_fn)]

type Field1 = i32;
Expand Down
6 changes: 3 additions & 3 deletions src/test/ui/consts/const-eval/union-ice.32bit.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0080]: it is undefined behavior to use this value
--> $DIR/union-ice.rs:15:1
--> $DIR/union-ice.rs:17:1
|
LL | const FIELD3: Field3 = unsafe { UNION.field3 };
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered uninitialized bytes, but expected initialized plain (non-pointer) bytes
Expand All @@ -10,7 +10,7 @@ LL | const FIELD3: Field3 = unsafe { UNION.field3 };
}

error[E0080]: it is undefined behavior to use this value
--> $DIR/union-ice.rs:17:1
--> $DIR/union-ice.rs:19:1
|
LL | / const FIELD_PATH: Struct = Struct {
LL | | a: 42,
Expand All @@ -24,7 +24,7 @@ LL | | };
}

error[E0080]: it is undefined behavior to use this value
--> $DIR/union-ice.rs:27:1
--> $DIR/union-ice.rs:29:1
|
LL | / const FIELD_PATH2: Struct2 = Struct2 {
LL | | b: [
Expand Down
6 changes: 3 additions & 3 deletions src/test/ui/consts/const-eval/union-ice.64bit.stderr
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
error[E0080]: it is undefined behavior to use this value
--> $DIR/union-ice.rs:15:1
--> $DIR/union-ice.rs:17:1
|
LL | const FIELD3: Field3 = unsafe { UNION.field3 };
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ type validation failed: encountered uninitialized bytes, but expected initialized plain (non-pointer) bytes
Expand All @@ -10,7 +10,7 @@ LL | const FIELD3: Field3 = unsafe { UNION.field3 };
}

error[E0080]: it is undefined behavior to use this value
--> $DIR/union-ice.rs:17:1
--> $DIR/union-ice.rs:19:1
|
LL | / const FIELD_PATH: Struct = Struct {
LL | | a: 42,
Expand All @@ -24,7 +24,7 @@ LL | | };
}

error[E0080]: it is undefined behavior to use this value
--> $DIR/union-ice.rs:27:1
--> $DIR/union-ice.rs:29:1
|
LL | / const FIELD_PATH2: Struct2 = Struct2 {
LL | | b: [
Expand Down
2 changes: 2 additions & 0 deletions src/test/ui/consts/const-eval/union-ice.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
// stderr-per-bitwidth
// ignore-wasm32
// ignore-wasm64
#![feature(const_fn)]

type Field1 = i32;
Expand Down

0 comments on commit 38f3c3b

Please sign in to comment.