Skip to content

Commit a9300fe

Browse files
committed
Update tests
1 parent 38784f2 commit a9300fe

25 files changed

Lines changed: 111 additions & 111 deletions

tests/unit/out/refcount/union_cross_arm_cast.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,21 +45,21 @@ impl Default for shape_b {
4545
}
4646
impl ByteRepr for shape_b {}
4747
#[derive()]
48-
pub union Container_anon_22_3 {
48+
pub union Container_anon_0 {
4949
pub a: Value<shape_a>,
5050
pub b: Value<shape_b>,
5151
pub raw_: Value<Box<[u8]>>,
5252
}
53-
impl Default for Container_anon_22_3 {
53+
impl Default for Container_anon_0 {
5454
fn default() -> Self {
5555
unsafe { std::mem::zeroed() }
5656
}
5757
}
58-
impl ByteRepr for Container_anon_22_3 {}
58+
impl ByteRepr for Container_anon_0 {}
5959
#[derive(Default)]
6060
pub struct Container {
6161
pub len: Value<u32>,
62-
pub u: Value<Container_anon_22_3>,
62+
pub u: Value<Container_anon_0>,
6363
}
6464
impl ByteRepr for Container {}
6565
pub fn main() {

tests/unit/out/refcount/union_field_alignment.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,20 +7,20 @@ use std::io::{Read, Seek, Write};
77
use std::os::fd::AsFd;
88
use std::rc::{Rc, Weak};
99
#[derive()]
10-
pub union node_anon_10_3 {
10+
pub union node_anon_0 {
1111
pub bytes: Value<Box<[u8]>>,
1212
pub aligner: Value<AnyPtr>,
1313
}
14-
impl Default for node_anon_10_3 {
14+
impl Default for node_anon_0 {
1515
fn default() -> Self {
1616
unsafe { std::mem::zeroed() }
1717
}
1818
}
19-
impl ByteRepr for node_anon_10_3 {}
19+
impl ByteRepr for node_anon_0 {}
2020
#[derive(Default)]
2121
pub struct node {
2222
pub next: Value<Ptr<node>>,
23-
pub x: Value<node_anon_10_3>,
23+
pub x: Value<node_anon_0>,
2424
}
2525
impl ByteRepr for node {}
2626
pub fn main() {

tests/unit/out/refcount/union_flex_array_member.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,20 +7,20 @@ use std::io::{Read, Seek, Write};
77
use std::os::fd::AsFd;
88
use std::rc::{Rc, Weak};
99
#[derive()]
10-
pub union node_anon_10_3 {
10+
pub union node_anon_0 {
1111
pub bytes: Value<Box<[u8]>>,
1212
pub aligner: Value<AnyPtr>,
1313
}
14-
impl Default for node_anon_10_3 {
14+
impl Default for node_anon_0 {
1515
fn default() -> Self {
1616
unsafe { std::mem::zeroed() }
1717
}
1818
}
19-
impl ByteRepr for node_anon_10_3 {}
19+
impl ByteRepr for node_anon_0 {}
2020
#[derive(Default)]
2121
pub struct node {
2222
pub len: Value<u64>,
23-
pub x: Value<node_anon_10_3>,
23+
pub x: Value<node_anon_0>,
2424
}
2525
impl ByteRepr for node {}
2626
pub fn main() {

tests/unit/out/refcount/union_memset_memcpy.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,20 +43,20 @@ impl Default for shape_b {
4343
}
4444
impl ByteRepr for shape_b {}
4545
#[derive()]
46-
pub union Container_anon_20_3 {
46+
pub union Container_anon_0 {
4747
pub a: Value<shape_a>,
4848
pub b: Value<shape_b>,
4949
pub raw_: Value<Box<[u8]>>,
5050
}
51-
impl Default for Container_anon_20_3 {
51+
impl Default for Container_anon_0 {
5252
fn default() -> Self {
5353
unsafe { std::mem::zeroed() }
5454
}
5555
}
56-
impl ByteRepr for Container_anon_20_3 {}
56+
impl ByteRepr for Container_anon_0 {}
5757
#[derive(Default)]
5858
pub struct Container {
59-
pub view: Value<Container_anon_20_3>,
59+
pub view: Value<Container_anon_0>,
6060
}
6161
impl ByteRepr for Container {}
6262
pub fn main() {

tests/unit/out/refcount/union_nested.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,39 +23,39 @@ impl Default for record {
2323
}
2424
impl ByteRepr for record {}
2525
#[derive()]
26-
pub union inner_anon_12_3 {
26+
pub union inner_anon_0 {
2727
pub h: Value<record>,
2828
pub raw_: Value<Box<[u8]>>,
2929
}
30-
impl Default for inner_anon_12_3 {
30+
impl Default for inner_anon_0 {
3131
fn default() -> Self {
3232
unsafe { std::mem::zeroed() }
3333
}
3434
}
35-
impl ByteRepr for inner_anon_12_3 {}
35+
impl ByteRepr for inner_anon_0 {}
3636
#[derive(Default)]
3737
pub struct inner {
38-
pub view: Value<inner_anon_12_3>,
38+
pub view: Value<inner_anon_0>,
3939
}
4040
impl ByteRepr for inner {}
4141
#[derive(Default)]
42-
pub union Outer_anon_23_3 {
42+
pub union Outer_anon_0 {
4343
pub h: Value<record>,
4444
pub nested: Value<inner>,
4545
}
46-
impl Default for Outer_anon_23_3 {
46+
impl Default for Outer_anon_0 {
4747
fn default() -> Self {
4848
unsafe { std::mem::zeroed() }
4949
}
5050
}
51-
impl ByteRepr for Outer_anon_23_3 {}
51+
impl ByteRepr for Outer_anon_0 {}
5252
#[derive(Default)]
5353
pub struct Outer {
5454
pub kind: Value<i32>,
5555
pub level: Value<i32>,
5656
pub variant: Value<i32>,
5757
pub len: Value<u32>,
58-
pub body: Value<Outer_anon_23_3>,
58+
pub body: Value<Outer_anon_0>,
5959
}
6060
impl ByteRepr for Outer {}
6161
pub fn main() {

tests/unit/out/refcount/union_pointer_pun_address.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,17 @@ fn main_0() -> i32 {
2525
n: Rc::new(RefCell::new(123)),
2626
}));
2727
#[derive(Default)]
28-
pub union anon_16_3 {
28+
pub union anon_0 {
2929
pub to_a: Value<Ptr<node_a>>,
3030
pub to_b: Value<Ptr<node_b>>,
3131
}
32-
impl Default for anon_16_3 {
32+
impl Default for anon_0 {
3333
fn default() -> Self {
3434
unsafe { std::mem::zeroed() }
3535
}
3636
}
37-
impl ByteRepr for anon_16_3 {};
38-
let ptr: Value<anon_16_3> = <Value<anon_16_3>>::default();
37+
impl ByteRepr for anon_0 {};
38+
let ptr: Value<anon_0> = <Value<anon_0>>::default();
3939
(*(*ptr.borrow()).to_a.borrow_mut()) = (a.as_pointer());
4040
let out: Value<Ptr<node_b>> = Rc::new(RefCell::new((*(*ptr.borrow()).to_b.borrow()).clone()));
4141
assert!({

tests/unit/out/refcount/union_pointer_pun_writethrough.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,17 @@ pub fn main() {
1212
fn main_0() -> i32 {
1313
let x: Value<i64> = Rc::new(RefCell::new((-1_i32 as i64)));
1414
#[derive(Default)]
15-
pub union anon_7_3 {
15+
pub union anon_0 {
1616
pub as_unsigned: Value<Ptr<u64>>,
1717
pub as_signed: Value<Ptr<i64>>,
1818
}
19-
impl Default for anon_7_3 {
19+
impl Default for anon_0 {
2020
fn default() -> Self {
2121
unsafe { std::mem::zeroed() }
2222
}
2323
}
24-
impl ByteRepr for anon_7_3 {};
25-
let pp: Value<anon_7_3> = <Value<anon_7_3>>::default();
24+
impl ByteRepr for anon_0 {};
25+
let pp: Value<anon_0> = <Value<anon_0>>::default();
2626
(*(*pp.borrow()).as_signed.borrow_mut()) = (x.as_pointer());
2727
(*(*pp.borrow()).as_unsigned.borrow()).write(42_u64);
2828
assert!(((*x.borrow()) == 42_i64));

tests/unit/out/refcount/union_struct_dual_use.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,19 @@ pub fn sum_inner_0(i: Ptr<Inner>) -> i32 {
2020
};
2121
}
2222
#[derive()]
23-
pub union Outer_anon_13_3 {
23+
pub union Outer_anon_0 {
2424
pub inner: Value<Inner>,
2525
pub raw_: Value<Box<[u8]>>,
2626
}
27-
impl Default for Outer_anon_13_3 {
27+
impl Default for Outer_anon_0 {
2828
fn default() -> Self {
2929
unsafe { std::mem::zeroed() }
3030
}
3131
}
32-
impl ByteRepr for Outer_anon_13_3 {}
32+
impl ByteRepr for Outer_anon_0 {}
3333
#[derive(Default)]
3434
pub struct Outer {
35-
pub u: Value<Outer_anon_13_3>,
35+
pub u: Value<Outer_anon_0>,
3636
}
3737
impl ByteRepr for Outer {}
3838
pub fn main() {

tests/unit/out/refcount/union_tagged_many_arms.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,23 @@ enum Tag {
1616
T_REF = 4,
1717
}
1818
#[derive(Default)]
19-
pub union Slot_anon_15_3 {
19+
pub union Slot_anon_0 {
2020
pub text: Value<Ptr<u8>>,
2121
pub handle: Value<AnyPtr>,
2222
pub signed_n: Value<i64>,
2323
pub unsigned_n: Value<u64>,
2424
pub f: Value<f64>,
2525
}
26-
impl Default for Slot_anon_15_3 {
26+
impl Default for Slot_anon_0 {
2727
fn default() -> Self {
2828
unsafe { std::mem::zeroed() }
2929
}
3030
}
31-
impl ByteRepr for Slot_anon_15_3 {}
31+
impl ByteRepr for Slot_anon_0 {}
3232
#[derive(Default)]
3333
pub struct Slot {
3434
pub tag: Value<Tag>,
35-
pub payload: Value<Slot_anon_15_3>,
35+
pub payload: Value<Slot_anon_0>,
3636
}
3737
impl ByteRepr for Slot {}
3838
pub fn main() {

tests/unit/out/refcount/union_tagged_simple.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,21 @@ enum Kind {
1313
KIND_DONE = 1,
1414
}
1515
#[derive(Default)]
16-
pub union Event_anon_12_3 {
16+
pub union Event_anon_0 {
1717
pub obj: Value<AnyPtr>,
1818
pub code: Value<i32>,
1919
}
20-
impl Default for Event_anon_12_3 {
20+
impl Default for Event_anon_0 {
2121
fn default() -> Self {
2222
unsafe { std::mem::zeroed() }
2323
}
2424
}
25-
impl ByteRepr for Event_anon_12_3 {}
25+
impl ByteRepr for Event_anon_0 {}
2626
#[derive(Default)]
2727
pub struct Event {
2828
pub kind: Value<Kind>,
2929
pub handle: Value<AnyPtr>,
30-
pub payload: Value<Event_anon_12_3>,
30+
pub payload: Value<Event_anon_0>,
3131
}
3232
impl ByteRepr for Event {}
3333
pub fn main() {

0 commit comments

Comments
 (0)