rust/tests/ui/layout/debug.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

520 lines
14 KiB
Plaintext
Raw Normal View History

2020-04-06 02:22:48 -05:00
error: layout_of(E) = Layout {
2022-07-30 20:39:15 -05:00
size: Size(12 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Arbitrary {
offsets: [
Size(0 bytes),
],
memory_index: [
0,
],
},
2022-07-30 20:39:15 -05:00
largest_niche: Some(
Niche {
offset: Size(0 bytes),
value: Int(
I32,
false,
),
valid_range: 0..=0,
},
),
variants: Multiple {
tag: Initialized {
value: Int(
I32,
false,
),
valid_range: 0..=0,
},
tag_encoding: Direct,
tag_field: 0,
variants: [
Layout {
2022-07-30 20:39:15 -05:00
size: Size(4 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Arbitrary {
offsets: [],
memory_index: [],
},
2022-07-30 20:39:15 -05:00
largest_niche: None,
variants: Single {
index: 0,
},
2022-07-30 20:39:15 -05:00
},
Layout {
size: Size(12 bytes),
align: AbiAndPrefAlign {
2022-07-30 20:39:15 -05:00
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
2022-07-30 20:39:15 -05:00
abi: Uninhabited,
fields: Arbitrary {
offsets: [
Size(4 bytes),
Size(4 bytes),
Size(8 bytes),
],
memory_index: [
0,
1,
2,
],
},
2022-07-30 20:39:15 -05:00
largest_niche: None,
variants: Single {
index: 1,
},
},
],
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:7:1
2020-03-10 16:31:27 -05:00
|
LL | enum E { Foo, Bar(!, i32, i32) }
2022-02-13 09:27:59 -06:00
| ^^^^^^
2020-03-10 16:31:27 -05:00
2020-04-06 02:22:48 -05:00
error: layout_of(S) = Layout {
2022-07-30 20:39:15 -05:00
size: Size(8 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: ScalarPair(
Initialized {
value: Int(
I32,
true,
),
valid_range: 0..=4294967295,
},
Initialized {
value: Int(
I32,
true,
),
valid_range: 0..=4294967295,
},
),
2022-07-30 20:39:15 -05:00
fields: Arbitrary {
offsets: [
Size(0 bytes),
Size(0 bytes),
Size(4 bytes),
],
memory_index: [
1,
0,
2,
],
},
largest_niche: None,
2022-07-30 20:39:15 -05:00
variants: Single {
index: 0,
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:10:1
|
LL | struct S { f1: i32, f2: (), f3: i32 }
2022-02-13 09:27:59 -06:00
| ^^^^^^^^
2020-04-06 02:22:48 -05:00
error: layout_of(U) = Layout {
2022-07-30 20:39:15 -05:00
size: Size(8 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
2022-07-30 20:39:15 -05:00
fields: Union(
2,
),
largest_niche: None,
2022-07-30 20:39:15 -05:00
variants: Single {
index: 0,
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:13:1
|
LL | union U { f1: (i32, i32), f3: i32 }
2022-02-13 09:27:59 -06:00
| ^^^^^^^
2020-04-06 02:22:48 -05:00
error: layout_of(std::result::Result<i32, i32>) = Layout {
2022-07-30 20:39:15 -05:00
size: Size(8 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: ScalarPair(
Initialized {
value: Int(
I32,
false,
),
valid_range: 0..=1,
},
Initialized {
value: Int(
I32,
true,
),
valid_range: 0..=4294967295,
},
),
fields: Arbitrary {
offsets: [
Size(0 bytes),
],
memory_index: [
0,
],
},
2022-07-30 20:39:15 -05:00
largest_niche: Some(
Niche {
offset: Size(0 bytes),
value: Int(
I32,
false,
),
valid_range: 0..=1,
},
),
variants: Multiple {
tag: Initialized {
value: Int(
I32,
false,
),
valid_range: 0..=1,
},
tag_encoding: Direct,
tag_field: 0,
variants: [
Layout {
2022-07-30 20:39:15 -05:00
size: Size(8 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: ScalarPair(
Initialized {
value: Int(
I32,
false,
),
valid_range: 0..=1,
},
Initialized {
value: Int(
I32,
true,
),
valid_range: 0..=4294967295,
},
),
fields: Arbitrary {
offsets: [
Size(4 bytes),
],
memory_index: [
0,
],
},
2022-07-30 20:39:15 -05:00
largest_niche: None,
variants: Single {
2022-07-30 20:39:15 -05:00
index: 0,
},
},
Layout {
size: Size(8 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: ScalarPair(
Initialized {
value: Int(
I32,
false,
),
valid_range: 0..=1,
},
Initialized {
value: Int(
I32,
true,
),
valid_range: 0..=4294967295,
},
),
2022-07-30 20:39:15 -05:00
fields: Arbitrary {
offsets: [
Size(4 bytes),
],
memory_index: [
0,
],
},
largest_niche: None,
2022-07-30 20:39:15 -05:00
variants: Single {
index: 1,
},
},
],
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:16:1
|
LL | type Test = Result<i32, i32>;
2022-02-13 09:27:59 -06:00
| ^^^^^^^^^
2020-04-06 02:22:48 -05:00
error: layout_of(i32) = Layout {
2022-07-30 20:39:15 -05:00
size: Size(4 bytes),
align: AbiAndPrefAlign {
abi: Align(4 bytes),
pref: $PREF_ALIGN,
},
abi: Scalar(
Initialized {
value: Int(
I32,
true,
),
valid_range: 0..=4294967295,
},
),
2022-07-30 20:39:15 -05:00
fields: Primitive,
largest_niche: None,
2022-07-30 20:39:15 -05:00
variants: Single {
index: 0,
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:19:1
|
LL | type T = impl std::fmt::Debug;
2022-02-13 09:27:59 -06:00
| ^^^^^^
error: layout_of(V) = Layout {
size: Size(2 bytes),
align: AbiAndPrefAlign {
abi: Align(2 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
2,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:22:1
|
LL | pub union V {
| ^^^^^^^^^^^
error: layout_of(W) = Layout {
size: Size(2 bytes),
align: AbiAndPrefAlign {
abi: Align(2 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
2,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:28:1
|
LL | pub union W {
| ^^^^^^^^^^^
error: layout_of(Y) = Layout {
size: Size(0 bytes),
align: AbiAndPrefAlign {
abi: Align(2 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
2,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
2023-02-18 19:42:16 -06:00
--> $DIR/debug.rs:34:1
|
LL | pub union Y {
| ^^^^^^^^^^^
2023-02-18 19:42:16 -06:00
error: layout_of(P1) = Layout {
size: Size(4 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
1,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
--> $DIR/debug.rs:41:1
|
LL | union P1 { x: u32 }
| ^^^^^^^^
error: layout_of(P2) = Layout {
size: Size(8 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
1,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
--> $DIR/debug.rs:45:1
|
LL | union P2 { x: (u32, u32) }
| ^^^^^^^^
error: layout_of(P3) = Layout {
size: Size(16 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
1,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
--> $DIR/debug.rs:53:1
|
LL | union P3 { x: F32x4 }
| ^^^^^^^^
error: layout_of(P4) = Layout {
size: Size(12 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Aggregate {
sized: true,
},
fields: Union(
1,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
--> $DIR/debug.rs:57:1
|
LL | union P4 { x: E }
| ^^^^^^^^
error: layout_of(P5) = Layout {
size: Size(1 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Scalar(
Union {
value: Int(
I8,
false,
),
},
),
fields: Union(
2,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
--> $DIR/debug.rs:61:1
|
LL | union P5 { zst: [u16; 0], byte: u8 }
| ^^^^^^^^
error: layout_of(std::mem::MaybeUninit<u8>) = Layout {
size: Size(1 bytes),
align: AbiAndPrefAlign {
abi: Align(1 bytes),
pref: $PREF_ALIGN,
},
abi: Scalar(
Union {
value: Int(
I8,
false,
),
},
),
fields: Union(
2,
),
largest_niche: None,
variants: Single {
index: 0,
},
}
--> $DIR/debug.rs:64:1
|
LL | type X = std::mem::MaybeUninit<u8>;
| ^^^^^^
error: aborting due to 14 previous errors
2020-03-10 16:31:27 -05:00