]>
git.proxmox.com Git - rustc.git/blob - src/test/debuginfo/generic-function.rs
1 // min-lldb-version: 310
5 // === GDB TESTS ===================================================================================
9 // gdb-command:print *t0
11 // gdb-command:print *t1
13 // gdb-command:continue
15 // gdb-command:print *t0
17 // gdb-command:print *t1
19 // gdb-command:continue
21 // gdb-command:print *t0
23 // gdb-command:print *t1
24 // gdbg-check:$6 = {a = 6, b = 7.5}
25 // gdbr-check:$6 = generic_function::Struct {a: 6, b: 7.5}
26 // gdb-command:continue
28 // === LLDB TESTS ==================================================================================
32 // lldb-command:print *t0
33 // lldbg-check:[...]$0 = 1
34 // lldbr-check:(i32) *t0 = 1
35 // lldb-command:print *t1
36 // lldbg-check:[...]$1 = 2.5
37 // lldbr-check:(f64) *t1 = 2.5
38 // lldb-command:continue
40 // lldb-command:print *t0
41 // lldbg-check:[...]$2 = 3.5
42 // lldbr-check:(f64) *t0 = 3.5
43 // lldb-command:print *t1
44 // lldbg-check:[...]$3 = 4
45 // lldbr-check:(u16) *t1 = 4
46 // lldb-command:continue
48 // lldb-command:print *t0
49 // lldbg-check:[...]$4 = 5
50 // lldbr-check:(i32) *t0 = 5
51 // lldb-command:print *t1
52 // lldbg-check:[...]$5 = { a = 6 b = 7.5 }
53 // lldbr-check:(generic_function::Struct) *t1 = { a = 6 b = 7.5 }
54 // lldb-command:continue
56 #![feature(omit_gdb_pretty_printer_section)]
57 #![omit_gdb_pretty_printer_section]
65 fn dup_tup
<T0
: Clone
, T1
: Clone
>(t0
: &T0
, t1
: &T1
) -> ((T0
, T1
), (T1
, T0
)) {
66 let ret
= ((t0
.clone(), t1
.clone()), (t1
.clone(), t0
.clone()));
73 let _
= dup_tup(&1, &2.5f64);
74 let _
= dup_tup(&3.5f64, &4_u16);
75 let _
= dup_tup(&5, &Struct { a: 6, b: 7.5 }
);