]> git.lizzy.rs Git - rust.git/commitdiff
debuginfo: Add LLDB autotests to debuginfo test suite.
authorMichael Woerister <michaelwoerister@posteo>
Wed, 9 Jul 2014 12:46:09 +0000 (14:46 +0200)
committerMichael Woerister <michaelwoerister@posteo>
Wed, 16 Jul 2014 07:46:31 +0000 (09:46 +0200)
This commit adds LLDB autotests to the test suite but does not activate them by default yet.

82 files changed:
src/test/debuginfo/basic-types.rs
src/test/debuginfo/borrowed-basic.rs
src/test/debuginfo/borrowed-c-style-enum.rs
src/test/debuginfo/borrowed-enum.rs
src/test/debuginfo/borrowed-managed-basic.rs
src/test/debuginfo/borrowed-struct.rs
src/test/debuginfo/borrowed-tuple.rs
src/test/debuginfo/borrowed-unique-basic.rs
src/test/debuginfo/box.rs
src/test/debuginfo/boxed-struct.rs
src/test/debuginfo/by-value-non-immediate-argument.rs
src/test/debuginfo/by-value-self-argument-in-trait-impl.rs
src/test/debuginfo/c-style-enum-in-composite.rs
src/test/debuginfo/c-style-enum.rs
src/test/debuginfo/closure-in-generic-function.rs
src/test/debuginfo/destructured-fn-argument.rs
src/test/debuginfo/destructured-local.rs
src/test/debuginfo/evec-in-struct.rs
src/test/debuginfo/function-arg-initialization.rs
src/test/debuginfo/function-arguments.rs
src/test/debuginfo/function-prologue-stepping-no-split-stack.rs
src/test/debuginfo/function-prologue-stepping-regular.rs [new file with mode: 0644]
src/test/debuginfo/generic-function.rs
src/test/debuginfo/generic-functions-nested.rs
src/test/debuginfo/generic-method-on-generic-struct.rs
src/test/debuginfo/generic-struct.rs
src/test/debuginfo/generic-tuple-style-enum.rs
src/test/debuginfo/include_string.rs
src/test/debuginfo/lexical-scope-in-for-loop.rs
src/test/debuginfo/lexical-scope-in-if.rs
src/test/debuginfo/lexical-scope-in-match.rs
src/test/debuginfo/lexical-scope-in-stack-closure.rs
src/test/debuginfo/lexical-scope-in-unconditional-loop.rs
src/test/debuginfo/lexical-scope-in-unique-closure.rs
src/test/debuginfo/lexical-scope-in-while.rs
src/test/debuginfo/lexical-scope-with-macro.rs
src/test/debuginfo/lexical-scopes-in-block-expression.rs
src/test/debuginfo/limited-debuginfo.rs
src/test/debuginfo/managed-enum.rs
src/test/debuginfo/managed-pointer-within-unique-vec.rs
src/test/debuginfo/managed-pointer-within-unique.rs
src/test/debuginfo/method-on-enum.rs
src/test/debuginfo/method-on-generic-struct.rs
src/test/debuginfo/method-on-struct.rs
src/test/debuginfo/method-on-trait.rs
src/test/debuginfo/method-on-tuple-struct.rs
src/test/debuginfo/multiple-functions-equal-var-names.rs
src/test/debuginfo/multiple-functions.rs
src/test/debuginfo/name-shadowing-and-scope-nesting.rs
src/test/debuginfo/nil-enum.rs
src/test/debuginfo/option-like-enum.rs
src/test/debuginfo/packed-struct-with-destructor.rs
src/test/debuginfo/packed-struct.rs
src/test/debuginfo/recursive-enum.rs
src/test/debuginfo/recursive-struct.rs
src/test/debuginfo/self-in-default-method.rs
src/test/debuginfo/self-in-generic-default-method.rs
src/test/debuginfo/shadowed-argument.rs
src/test/debuginfo/shadowed-variable.rs
src/test/debuginfo/simd.rs
src/test/debuginfo/simple-lexical-scope.rs
src/test/debuginfo/simple-struct.rs
src/test/debuginfo/simple-tuple.rs
src/test/debuginfo/static-method-on-struct-and-enum.rs
src/test/debuginfo/struct-in-enum.rs
src/test/debuginfo/struct-in-struct.rs
src/test/debuginfo/struct-style-enum.rs
src/test/debuginfo/struct-with-destructor.rs
src/test/debuginfo/text-to-include-1.txt
src/test/debuginfo/text-to-include-2.txt
src/test/debuginfo/text-to-include-3.txt
src/test/debuginfo/trait-generic-static-default-method.rs
src/test/debuginfo/trait-pointers.rs
src/test/debuginfo/tuple-in-tuple.rs
src/test/debuginfo/tuple-struct.rs
src/test/debuginfo/tuple-style-enum.rs
src/test/debuginfo/unique-enum.rs
src/test/debuginfo/var-captured-in-nested-closure.rs
src/test/debuginfo/var-captured-in-sendable-closure.rs
src/test/debuginfo/var-captured-in-stack-closure.rs
src/test/debuginfo/vec-slices.rs
src/test/debuginfo/vec.rs

index ae554cafb507c4ac4ff3bd61d5fdc8c6ed8af3e0..67f77014c9fa98ac3d1a3be2612add364097aff0 100644 (file)
@@ -17,6 +17,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print f64
 // gdb-check:$14 = 3.5
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+// lldb-command:print b
+// lldb-check:[...]$0 = false
+// lldb-command:print i
+// lldb-check:[...]$1 = -1
+
+// NOTE: LLDB does not support 32bit chars
+// d ebugger:print (uint)(c)
+// c heck:$3 = 97
+
+// lldb-command:print i8
+// lldb-check:[...]$2 = 'D'
+// lldb-command:print i16
+// lldb-check:[...]$3 = -16
+// lldb-command:print i32
+// lldb-check:[...]$4 = -32
+// lldb-command:print i64
+// lldb-check:[...]$5 = -64
+// lldb-command:print u
+// lldb-check:[...]$6 = 1
+// lldb-command:print u8
+// lldb-check:[...]$7 = 'd'
+// lldb-command:print u16
+// lldb-check:[...]$8 = 16
+// lldb-command:print u32
+// lldb-check:[...]$9 = 32
+// lldb-command:print u64
+// lldb-check:[...]$10 = 64
+// lldb-command:print f32
+// lldb-check:[...]$11 = 2.5
+// lldb-command:print f64
+// lldb-check:[...]$12 = 3.5
+
 #![allow(unused_variable)]
 
 fn main() {
@@ -66,7 +105,7 @@ fn main() {
     let u64: u64 = 64;
     let f32: f32 = 2.5;
     let f64: f64 = 3.5;
-    _zzz();
+    _zzz(); // #break
 }
 
 fn _zzz() {()}
index d511e5ed20f8ec49a22d7c070240c1596a344c03..84610b3c740517985ccc26b59eeafb29be0fa468 100644 (file)
@@ -14,6 +14,9 @@
 // its numerical value.
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *f64_ref
 // gdb-check:$14 = 3.5
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+// lldb-command:print *bool_ref
+// lldb-check:[...]$0 = true
+
+// lldb-command:print *int_ref
+// lldb-check:[...]$1 = -1
+
+// NOTE: lldb doesn't support 32bit chars at the moment
+// d ebugger:print *char_ref
+// c heck:[...]$x = 97
+
+// lldb-command:print *i8_ref
+// lldb-check:[...]$2 = 'D'
+
+// lldb-command:print *i16_ref
+// lldb-check:[...]$3 = -16
+
+// lldb-command:print *i32_ref
+// lldb-check:[...]$4 = -32
+
+// lldb-command:print *i64_ref
+// lldb-check:[...]$5 = -64
+
+// lldb-command:print *uint_ref
+// lldb-check:[...]$6 = 1
+
+// lldb-command:print *u8_ref
+// lldb-check:[...]$7 = 'd'
+
+// lldb-command:print *u16_ref
+// lldb-check:[...]$8 = 16
+
+// lldb-command:print *u32_ref
+// lldb-check:[...]$9 = 32
+
+// lldb-command:print *u64_ref
+// lldb-check:[...]$10 = 64
+
+// lldb-command:print *f32_ref
+// lldb-check:[...]$11 = 2.5
+
+// lldb-command:print *f64_ref
+// lldb-check:[...]$12 = 3.5
+
 #![allow(unused_variable)]
 
 fn main() {
@@ -103,7 +153,8 @@ fn main() {
 
     let f64_val: f64 = 3.5;
     let f64_ref: &f64 = &f64_val;
-    zzz();
+
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 9ab7e0701cc99c261d7c15abefaaa279ca3d3f9a..2270cfb6d215da80f8a18958cccb3a1d13cd163f 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *the_c_ref
 // gdb-check:$3 = TheC
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *the_a_ref
+// lldb-check:[...]$0 = TheA
+
+// lldb-command:print *the_b_ref
+// lldb-check:[...]$1 = TheB
+
+// lldb-command:print *the_c_ref
+// lldb-check:[...]$2 = TheC
+
 #![allow(unused_variable)]
 
 enum ABC { TheA, TheB, TheC }
@@ -38,7 +55,7 @@ fn main() {
     let the_c = TheC;
     let the_c_ref: &ABC = &the_c;
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index a377d68a33d8cbd9502a69848d8f1ab36714baae..b6f5096c726a5ec172cea6d922e298b6f7c0ffd8 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *univariant_ref
 // gdb-check:$3 = {{4820353753753434}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *the_a_ref
+// lldb-check:[...]$0 = TheA { x: 0, y: 8970181431921507452 }
+// lldb-command:print *the_b_ref
+// lldb-check:[...]$1 = TheB(0, 286331153, 286331153)
+// lldb-command:print *univariant_ref
+// lldb-check:[...]$2 = TheOnlyCase(4820353753753434)
+
 #![allow(unused_variable)]
 #![feature(struct_variant)]
 
@@ -59,7 +74,7 @@ fn main() {
     let univariant = TheOnlyCase(4820353753753434);
     let univariant_ref: &Univariant = &univariant;
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 0f81e530fdd36a25454501547896ed47a594d54d..82e44b46d3c8c10e183851b0cf6c2b7883475c8f 100644 (file)
@@ -16,6 +16,9 @@
 // its numerical value.
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *f64_ref
 // gdb-check:$14 = 3.5
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:type format add -f decimal char
+// lldb-command:type format add -f decimal 'unsigned char'
+// lldb-command:run
+
+// lldb-command:print *bool_ref
+// lldb-check:[...]$0 = true
+
+// lldb-command:print *int_ref
+// lldb-check:[...]$1 = -1
+
+// LLDB can't handle 32bit chars yet
+// d ebugger:print *char_ref
+// c heck:[...]$x = 97
+
+// lldb-command:print *i8_ref
+// lldb-check:[...]$2 = 68
+
+// lldb-command:print *i16_ref
+// lldb-check:[...]$3 = -16
+
+// lldb-command:print *i32_ref
+// lldb-check:[...]$4 = -32
+
+// lldb-command:print *i64_ref
+// lldb-check:[...]$5 = -64
+
+// lldb-command:print *uint_ref
+// lldb-check:[...]$6 = 1
+
+// lldb-command:print *u8_ref
+// lldb-check:[...]$7 = 100
+
+// lldb-command:print *u16_ref
+// lldb-check:[...]$8 = 16
+
+// lldb-command:print *u32_ref
+// lldb-check:[...]$9 = 32
+
+// lldb-command:print *u64_ref
+// lldb-check:[...]$10 = 64
+
+// lldb-command:print *f32_ref
+// lldb-check:[...]$11 = 2.5
+
+// lldb-command:print *f64_ref
+// lldb-check:[...]$12 = 3.5
+
 #![allow(unused_variable)]
 
 use std::gc::{Gc, GC};
@@ -107,7 +160,8 @@ fn main() {
 
     let f64_box: Gc<f64> = box(GC) 3.5;
     let f64_ref: &f64 = f64_box;
-    zzz();
+
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 98b66098862b519c0a41c2d46a53022b11ebbaa3..5ad0fe89d2cdfefd7916d0fd6e2de4ed0f22a2b1 100644 (file)
@@ -9,8 +9,10 @@
 // except according to those terms.
 
 // ignore-android: FIXME(#10381)
-
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *unique_val_interior_ref_2
 // gdb-check:$10 = 26.5
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *stack_val_ref
+// lldb-check:[...]$0 = SomeStruct { x: 10, y: 23.5 }
+
+// lldb-command:print *stack_val_interior_ref_1
+// lldb-check:[...]$1 = 10
+
+// lldb-command:print *stack_val_interior_ref_2
+// lldb-check:[...]$2 = 23.5
+
+// lldb-command:print *ref_to_unnamed
+// lldb-check:[...]$3 = SomeStruct { x: 11, y: 24.5 }
+
+// lldb-command:print *managed_val_ref
+// lldb-check:[...]$4 = SomeStruct { x: 12, y: 25.5 }
+
+// lldb-command:print *managed_val_interior_ref_1
+// lldb-check:[...]$5 = 12
+
+// lldb-command:print *managed_val_interior_ref_2
+// lldb-check:[...]$6 = 25.5
+
+// lldb-command:print *unique_val_ref
+// lldb-check:[...]$7 = SomeStruct { x: 13, y: 26.5 }
+
+// lldb-command:print *unique_val_interior_ref_1
+// lldb-check:[...]$8 = 13
+
+// lldb-command:print *unique_val_interior_ref_2
+// lldb-check:[...]$9 = 26.5
+
 #![feature(managed_boxes)]
 #![allow(unused_variable)]
 
@@ -72,7 +109,7 @@ fn main() {
     let unique_val_interior_ref_1: &int = &unique_val.x;
     let unique_val_interior_ref_2: &f64 = &unique_val.y;
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index b88161e4a0b30a5d39a7f7a775101cb8812a74b0..5c20c7471ec26a012f64cc7455109fb4100527ac 100644 (file)
@@ -13,6 +13,9 @@
 #![feature(managed_boxes)]
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *unique_val_ref
 // gdb-check:$4 = {-17, -22}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *stack_val_ref
+// lldb-check:[...]$0 = (-14, -19)
+
+// lldb-command:print *ref_to_unnamed
+// lldb-check:[...]$1 = (-15, -20)
+
+// lldb-command:print *managed_val_ref
+// lldb-check:[...]$2 = (-16, -21)
+
+// lldb-command:print *unique_val_ref
+// lldb-check:[...]$3 = (-17, -22)
+
+
 #![allow(unused_variable)]
 
 use std::gc::{Gc, GC};
@@ -44,7 +65,7 @@ fn main() {
     let unique_val: Box<(i16, f32)> = box() (-17, -22f32);
     let unique_val_ref: &(i16, f32) = unique_val;
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 6e8fa62ed26c864c7a88933944a1d34af353866c..821c85fdcf3a06e54415014cdc1e9e3bc45d313a 100644 (file)
@@ -14,6 +14,9 @@
 // its numerical value.
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *f64_ref
 // gdb-check:$14 = 3.5
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:type format add -f decimal char
+// lldb-command:type format add -f decimal 'unsigned char'
+// lldb-command:run
+
+// lldb-command:print *bool_ref
+// lldb-check:[...]$0 = true
+
+// lldb-command:print *int_ref
+// lldb-check:[...]$1 = -1
+
+// d ebugger:print *char_ref
+// c heck:[...]$3 = 97
+
+// lldb-command:print *i8_ref
+// lldb-check:[...]$2 = 68
+
+// lldb-command:print *i16_ref
+// lldb-check:[...]$3 = -16
+
+// lldb-command:print *i32_ref
+// lldb-check:[...]$4 = -32
+
+// lldb-command:print *i64_ref
+// lldb-check:[...]$5 = -64
+
+// lldb-command:print *uint_ref
+// lldb-check:[...]$6 = 1
+
+// lldb-command:print *u8_ref
+// lldb-check:[...]$7 = 100
+
+// lldb-command:print *u16_ref
+// lldb-check:[...]$8 = 16
+
+// lldb-command:print *u32_ref
+// lldb-check:[...]$9 = 32
+
+// lldb-command:print *u64_ref
+// lldb-check:[...]$10 = 64
+
+// lldb-command:print *f32_ref
+// lldb-check:[...]$11 = 2.5
+
+// lldb-command:print *f64_ref
+// lldb-check:[...]$12 = 3.5
+
 #![allow(unused_variable)]
 
 
@@ -104,7 +156,8 @@ fn main() {
 
     let f64_box: Box<f64> = box 3.5;
     let f64_ref: &f64 = f64_box;
-    zzz();
+
+    zzz(); // #break
 }
 
 fn zzz() {()}
index dcfe1804510ad59364b060b30591a10f29731a75..5b799b25bbfc4dc287b3fe4f3714da46358be990 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print d->val
 // gdb-check:$4 = false
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+// lldb-command:print *a
+// lldb-check:[...]$0 = 1
+// lldb-command:print *b
+// lldb-check:[...]$1 = (2, 3.5)
+// lldb-command:print c->val
+// lldb-check:[...]$2 = 4
+// lldb-command:print d->val
+// lldb-check:[...]$3 = false
+
 #![feature(managed_boxes)]
 #![allow(unused_variable)]
 
@@ -34,7 +50,8 @@ fn main() {
     let b = box() (2i, 3.5f64);
     let c = box(GC) 4i;
     let d = box(GC) false;
-    _zzz();
+
+    zzz(); // #break
 }
 
-fn _zzz() {()}
+fn zzz() { () }
index f583016b93f392220d409b3a84be45af545d651c..0e958545fb3c09105c6cf068a7ab4b4c39685a0d 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print managed_dtor->val
 // gdb-check:$4 = {x = 33, y = 333, z = 3333, w = 33333}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *unique
+// lldb-check:[...]$0 = StructWithSomePadding { x: 99, y: 999, z: 9999, w: 99999 }
+
+// lldb-command:print managed->val
+// lldb-check:[...]$1 = StructWithSomePadding { x: 88, y: 888, z: 8888, w: 88888 }
+
+// lldb-command:print *unique_dtor
+// lldb-check:[...]$2 = StructWithDestructor { x: 77, y: 777, z: 7777, w: 77777 }
+
+// lldb-command:print managed_dtor->val
+// lldb-check:[...]$3 = StructWithDestructor { x: 33, y: 333, z: 3333, w: 33333 }
+
 #![feature(managed_boxes)]
 #![allow(unused_variable)]
 
@@ -58,7 +78,7 @@ fn main() {
     let unique_dtor = box StructWithDestructor { x: 77, y: 777, z: 7777, w: 77777 };
     let managed_dtor = box(GC) StructWithDestructor { x: 33, y: 333, z: 3333, w: 33333 };
 
-    zzz();
+    zzz(); // #break
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 873e062352107bd214305c18a230d9e6422fd19a..2e1c4c79af0b336887a6f964fd5f84ba3122f535 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$7 = {{Case1, x = 0, y = 8970181431921507452}, {Case1, 0, 2088533116, 2088533116}}
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print s
+// lldb-check:[...]$0 = Struct { a: 1, b: 2.5 }
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = Struct { a: 3, b: 4.5 }
+// lldb-command:print y
+// lldb-check:[...]$2 = 5
+// lldb-command:print z
+// lldb-check:[...]$3 = 6.5
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$4 = (7, 8, 9.5, 10.5)
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$5 = Newtype(11.5, 12.5, 13, 14)
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$6 = Case1 { x: 0, y: 8970181431921507452 }
+// lldb-command:continue
+
 #![feature(struct_variant)]
 
 #[deriving(Clone)]
@@ -58,21 +90,21 @@ struct StructStruct {
 }
 
 fn fun(s: Struct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn fun_fun(StructStruct { a: x, b: Struct { a: y, b: z } }: StructStruct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn tup(a: (int, uint, f64, f64)) {
-    zzz();
+    zzz(); // #break
 }
 
 struct Newtype(f64, f64, int, uint);
 
 fn new_type(a: Newtype) {
-    zzz();
+    zzz(); // #break
 }
 
 // The first element is to ensure proper alignment, irrespective of the machines word size. Since
@@ -84,7 +116,7 @@ enum Enum {
 }
 
 fn by_val_enum(x: Enum) {
-    zzz();
+    zzz(); // #break
 }
 
 fn main() {
@@ -100,4 +132,4 @@ fn main() {
     by_val_enum(Case1 { x: 0, y: 8970181431921507452 });
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 0da2d44d5ae50061e80eb558f142fc5d9dfc6ba2..4d6064c185b4c97cf15abec9ce5d982dea313623 100644 (file)
@@ -13,6 +13,9 @@
 #![feature(managed_boxes)]
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$4 = 8888
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print self
+// lldb-check:[...]$0 = 1111
+// lldb-command:continue
+
+// lldb-command:print self
+// lldb-check:[...]$1 = Struct { x: 2222, y: 3333 }
+// lldb-command:continue
+
+// lldb-command:print self
+// lldb-check:[...]$2 = (4444.5, 5555, 6666, 7777.5)
+// lldb-command:continue
+
+// lldb-command:print self->val
+// lldb-check:[...]$3 = 8888
+// lldb-command:continue
+
 use std::gc::{Gc, GC};
 
 trait Trait {
@@ -44,7 +68,7 @@ trait Trait {
 
 impl Trait for int {
     fn method(self) -> int {
-        zzz();
+        zzz(); // #break
         self
     }
 }
@@ -56,21 +80,21 @@ struct Struct {
 
 impl Trait for Struct {
     fn method(self) -> Struct {
-        zzz();
+        zzz(); // #break
         self
     }
 }
 
 impl Trait for (f64, int, int, f64) {
     fn method(self) -> (f64, int, int, f64) {
-        zzz();
+        zzz(); // #break
         self
     }
 }
 
 impl Trait for Gc<int> {
     fn method(self) -> Gc<int> {
-        zzz();
+        zzz(); // #break
         self
     }
 }
@@ -82,4 +106,4 @@ fn main() {
     let _ = (box(GC) 8888).method();
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 3e76bf1987b98b487369f973ffd55589185af11e..f73517282907f87f4614ba5f6ce122a5f8157e9a 100644 (file)
@@ -8,9 +8,13 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// ignore-tidy-linelength
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print struct_with_drop
 // gdb-check:$7 = {{a = OneHundred, b = Vienna}, 9}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print tuple_interior_padding
+// lldb-check:[...]$0 = (0, OneHundred)
+
+// lldb-command:print tuple_padding_at_end
+// lldb-check:[...]$1 = ((1, OneThousand), 2)
+// lldb-command:print tuple_different_enums
+// lldb-check:[...]$2 = (OneThousand, MountainView, OneMillion, Vienna)
+
+// lldb-command:print padded_struct
+// lldb-check:[...]$3 = PaddedStruct { a: 3, b: OneMillion, c: 4, d: Toronto, e: 5 }
+
+// lldb-command:print packed_struct
+// lldb-check:[...]$4 = PackedStruct { a: 6, b: OneHundred, c: 7, d: Vienna, e: 8 }
+
+// lldb-command:print non_padded_struct
+// lldb-check:[...]$5 = NonPaddedStruct { a: OneMillion, b: MountainView, c: OneThousand, d: Toronto }
+
+// lldb-command:print struct_with_drop
+// lldb-check:[...]$6 = (StructWithDrop { a: OneHundred, b: Vienna }, 9)
+
 #![allow(unused_variable)]
 
 enum AnEnum {
@@ -115,7 +144,7 @@ fn main() {
 
     let struct_with_drop = (StructWithDrop { a: OneHundred, b: Vienna }, 9_i64);
 
-    zzz();
+    zzz(); // #break
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 19f8398f1a94b594918ba41b06def6bc7a1f0287..da30363f271d07bf878657746d4329fe30c981c1 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 
 // gdb-command:print 'c-style-enum::SINGLE_VARIANT'
 // gdb-command:print 'c-style-enum::MANUAL_THREE'
 // gdb-check:$18 = OneMillion
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print auto_one
+// lldb-check:[...]$0 = One
+
+// lldb-command:print auto_two
+// lldb-check:[...]$1 = Two
+
+// lldb-command:print auto_three
+// lldb-check:[...]$2 = Three
+
+// lldb-command:print manual_one_hundred
+// lldb-check:[...]$3 = OneHundred
+
+// lldb-command:print manual_one_thousand
+// lldb-check:[...]$4 = OneThousand
+
+// lldb-command:print manual_one_million
+// lldb-check:[...]$5 = OneMillion
+
+// lldb-command:print single_variant
+// lldb-check:[...]$6 = TheOnlyVariant
+
 #![allow(unused_variable)]
 #![allow(dead_code)]
 
@@ -120,11 +149,11 @@ fn main() {
         MANUAL_THREE = OneMillion;
     };
 
-    zzz();
+    zzz(); // #break
 
     let a = SINGLE_VARIANT;
     let a = unsafe { AUTO_ONE };
     let a = unsafe { MANUAL_ONE };
 }
 
-fn zzz() {()}
+fn zzz() { () }
index cc241040f2bd28335f178778a57a4fa77efdc34c..67601221e7a46debb0990b80d20b1efe2fb835f7 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$4 = 110
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = 0.5
+// lldb-command:print y
+// lldb-check:[...]$1 = 10
+// lldb-command:continue
+
+// lldb-command:print *x
+// lldb-check:[...]$2 = 29
+// lldb-command:print *y
+// lldb-check:[...]$3 = 110
+// lldb-command:continue
+
 fn some_generic_fun<T1, T2>(a: T1, b: T2) -> (T2, T1) {
 
     let closure = |x, y| {
-        zzz();
+        zzz(); // #break
         (y, x)
     };
 
@@ -43,4 +63,4 @@ fn main() {
     some_generic_fun(&29i, box 110i);
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 697703034f6e3735337e2e62d836ee966f401954..48d14a46c83f1d136846300a9c075009e2eaa8e1 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$49 = 62
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+// lldb-command:run
+
+// lldb-command:print a
+// lldb-check:[...]$0 = 1
+// lldb-command:print b
+// lldb-check:[...]$1 = false
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$2 = 2
+// lldb-command:print b
+// lldb-check:[...]$3 = 3
+// lldb-command:print c
+// lldb-check:[...]$4 = 4
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$5 = 5
+// lldb-command:print b
+// lldb-check:[...]$6 = (6, 7)
+// lldb-command:continue
+
+// lldb-command:print h
+// lldb-check:[...]$7 = 8
+// lldb-command:print i
+// lldb-check:[...]$8 = Struct { a: 9, b: 10 }
+// lldb-command:print j
+// lldb-check:[...]$9 = 11
+// lldb-command:continue
+
+// lldb-command:print k
+// lldb-check:[...]$10 = 12
+// lldb-command:print l
+// lldb-check:[...]$11 = 13
+// lldb-command:continue
+
+// lldb-command:print m
+// lldb-check:[...]$12 = 14
+// lldb-command:print n
+// lldb-check:[...]$13 = 16
+// lldb-command:continue
+
+// lldb-command:print o
+// lldb-check:[...]$14 = 18
+// lldb-command:continue
+
+// lldb-command:print p
+// lldb-check:[...]$15 = 19
+// lldb-command:print q
+// lldb-check:[...]$16 = 20
+// lldb-command:print r
+// lldb-check:[...]$17 = Struct { a: 21, b: 22 }
+// lldb-command:continue
+
+// lldb-command:print s
+// lldb-check:[...]$18 = 24
+// lldb-command:print t
+// lldb-check:[...]$19 = 23
+// lldb-command:continue
+
+// lldb-command:print u
+// lldb-check:[...]$20 = 25
+// lldb-command:print v
+// lldb-check:[...]$21 = 26
+// lldb-command:print w
+// lldb-check:[...]$22 = 27
+// lldb-command:print x
+// lldb-check:[...]$23 = 28
+// lldb-command:print y
+// lldb-check:[...]$24 = 29
+// lldb-command:print z
+// lldb-check:[...]$25 = 30
+// lldb-command:print ae
+// lldb-check:[...]$26 = 31
+// lldb-command:print oe
+// lldb-check:[...]$27 = 32
+// lldb-command:print ue
+// lldb-check:[...]$28 = 33
+// lldb-command:continue
+
+// lldb-command:print aa
+// lldb-check:[...]$29 = (34, 35)
+// lldb-command:continue
+
+// lldb-command:print bb
+// lldb-check:[...]$30 = (36, 37)
+// lldb-command:continue
+
+// lldb-command:print cc
+// lldb-check:[...]$31 = 38
+// lldb-command:continue
+
+// lldb-command:print dd
+// lldb-check:[...]$32 = (40, 41, 42)
+// lldb-command:continue
+
+// lldb-command:print *ee
+// lldb-check:[...]$33 = (43, 44, 45)
+// lldb-command:continue
+
+// lldb-command:print *ff
+// lldb-check:[...]$34 = 46
+// lldb-command:print gg
+// lldb-check:[...]$35 = (47, 48)
+// lldb-command:continue
+
+// lldb-command:print *hh
+// lldb-check:[...]$36 = 50
+// lldb-command:continue
+
+// lldb-command:print ii
+// lldb-check:[...]$37 = 51
+// lldb-command:continue
+
+// lldb-command:print *jj
+// lldb-check:[...]$38 = 52
+// lldb-command:continue
+
+// lldb-command:print kk
+// lldb-check:[...]$39 = 53
+// lldb-command:print ll
+// lldb-check:[...]$40 = 54
+// lldb-command:continue
+
+// lldb-command:print mm
+// lldb-check:[...]$41 = 55
+// lldb-command:print *nn
+// lldb-check:[...]$42 = 56
+// lldb-command:continue
+
+// lldb-command:print oo
+// lldb-check:[...]$43 = 57
+// lldb-command:print pp
+// lldb-check:[...]$44 = 58
+// lldb-command:print qq
+// lldb-check:[...]$45 = 59
+// lldb-command:continue
+
+// lldb-command:print rr
+// lldb-check:[...]$46 = 60
+// lldb-command:print ss
+// lldb-check:[...]$47 = 61
+// lldb-command:print tt
+// lldb-check:[...]$48 = 62
+// lldb-command:continue
+
 #![allow(unused_variable)]
 
 
@@ -197,93 +348,93 @@ enum Univariant {
 
 
 fn simple_tuple((a, b): (int, bool)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn nested_tuple((a, (b, c)): (int, (u16, u16))) {
-    zzz();
+    zzz(); // #break
 }
 
 fn destructure_only_first_level((a, b): (int, (u32, u32))) {
-    zzz();
+    zzz(); // #break
 }
 
 fn struct_as_tuple_element((h, i, j): (i16, Struct, i16)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn struct_pattern(Struct { a: k, b: l }: Struct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn ignored_tuple_element((m, _, n): (int, u16, i32)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn ignored_struct_field(Struct { b: o, .. }: Struct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn one_struct_destructured_one_not((Struct { a: p, b: q }, r): (Struct, Struct)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn different_order_of_struct_fields(Struct { b: s, a: t }: Struct ) {
-    zzz();
+    zzz(); // #break
 }
 
 fn complex_nesting(((u,   v  ), ((w,   (x,   Struct { a: y, b: z})), Struct { a: ae, b: oe }), ue ):
                    ((i16, i32), ((i64, (i32, Struct,             )), Struct                 ), u16))
 {
-    zzz();
+    zzz(); // #break
 }
 
 fn managed_box(&aa: &(int, int)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn borrowed_pointer(&bb: &(int, int)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn contained_borrowed_pointer((&cc, _): (&int, int)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn unique_pointer(box dd: Box<(int, int, int)>) {
-    zzz();
+    zzz(); // #break
 }
 
 fn ref_binding(ref ee: (int, int, int)) {
-    zzz();
+    zzz(); // #break
 }
 
 fn ref_binding_in_tuple((ref ff, gg): (int, (int, int))) {
-    zzz();
+    zzz(); // #break
 }
 
 fn ref_binding_in_struct(Struct { b: ref hh, .. }: Struct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn univariant_enum(Unit(ii): Univariant) {
-    zzz();
+    zzz(); // #break
 }
 
 fn univariant_enum_with_ref_binding(Unit(ref jj): Univariant) {
-    zzz();
+    zzz(); // #break
 }
 
 fn tuple_struct(TupleStruct(kk, ll): TupleStruct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn tuple_struct_with_ref_binding(TupleStruct(mm, ref nn): TupleStruct) {
-    zzz();
+    zzz(); // #break
 }
 
 fn multiple_arguments((oo, pp): (int, int), qq : int) {
-    zzz();
+    zzz(); // #break
 }
 
 fn main() {
@@ -311,11 +462,10 @@ fn main() {
     multiple_arguments((57, 58), 59);
 
     fn nested_function(rr: int, (ss, tt): (int, int)) {
-        zzz();
+        zzz(); // #break
     }
 
     nested_function(60, (61, 62));
 }
 
-
-fn zzz() {()}
+fn zzz() { () }
index d91d98f43050ff94d0aaff74378feb050e739dbf..837a6dc062227632972db27d1cfc08476b7ac537 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *nn
 // gdb-check:$43 = 56
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print a
+// lldb-check:[...]$0 = 1
+// lldb-command:print b
+// lldb-check:[...]$1 = false
+
+// lldb-command:print c
+// lldb-check:[...]$2 = 2
+// lldb-command:print d
+// lldb-check:[...]$3 = 3
+// lldb-command:print e
+// lldb-check:[...]$4 = 4
+
+// lldb-command:print f
+// lldb-check:[...]$5 = 5
+// lldb-command:print g
+// lldb-check:[...]$6 = (6, 7)
+
+// lldb-command:print h
+// lldb-check:[...]$7 = 8
+// lldb-command:print i
+// lldb-check:[...]$8 = Struct { a: 9, b: 10 }
+// lldb-command:print j
+// lldb-check:[...]$9 = 11
+
+// lldb-command:print k
+// lldb-check:[...]$10 = 12
+// lldb-command:print l
+// lldb-check:[...]$11 = 13
+
+// lldb-command:print m
+// lldb-check:[...]$12 = 14
+// lldb-command:print n
+// lldb-check:[...]$13 = 16
+
+// lldb-command:print o
+// lldb-check:[...]$14 = 18
+
+// lldb-command:print p
+// lldb-check:[...]$15 = 19
+// lldb-command:print q
+// lldb-check:[...]$16 = 20
+// lldb-command:print r
+// lldb-check:[...]$17 = Struct { a: 21, b: 22 }
+
+// lldb-command:print s
+// lldb-check:[...]$18 = 24
+// lldb-command:print t
+// lldb-check:[...]$19 = 23
+
+// lldb-command:print u
+// lldb-check:[...]$20 = 25
+// lldb-command:print v
+// lldb-check:[...]$21 = 26
+// lldb-command:print w
+// lldb-check:[...]$22 = 27
+// lldb-command:print x
+// lldb-check:[...]$23 = 28
+// lldb-command:print y
+// lldb-check:[...]$24 = 29
+// lldb-command:print z
+// lldb-check:[...]$25 = 30
+// lldb-command:print ae
+// lldb-check:[...]$26 = 31
+// lldb-command:print oe
+// lldb-check:[...]$27 = 32
+// lldb-command:print ue
+// lldb-check:[...]$28 = 33
+
+// lldb-command:print aa
+// lldb-check:[...]$29 = (34, 35)
+
+// lldb-command:print bb
+// lldb-check:[...]$30 = (36, 37)
+
+// lldb-command:print cc
+// lldb-check:[...]$31 = 38
+
+// lldb-command:print dd
+// lldb-check:[...]$32 = (40, 41, 42)
+
+// lldb-command:print *ee
+// lldb-check:[...]$33 = (43, 44, 45)
+
+// lldb-command:print *ff
+// lldb-check:[...]$34 = 46
+
+// lldb-command:print gg
+// lldb-check:[...]$35 = (47, 48)
+
+// lldb-command:print *hh
+// lldb-check:[...]$36 = 50
+
+// lldb-command:print ii
+// lldb-check:[...]$37 = 51
+
+// lldb-command:print *jj
+// lldb-check:[...]$38 = 52
+
+// lldb-command:print kk
+// lldb-check:[...]$39 = 53
+
+// lldb-command:print ll
+// lldb-check:[...]$40 = 54
+
+// lldb-command:print mm
+// lldb-check:[...]$41 = 55
+
+// lldb-command:print *nn
+// lldb-check:[...]$42 = 56
+
+
 #![allow(unused_variable)]
 
 struct Struct {
@@ -204,7 +323,7 @@ fn main() {
     // tuple struct with ref binding
     let &TupleStruct(mm, ref nn) = &TupleStruct(55.0, 56);
 
-    zzz();
+    zzz(); // #break
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 913038c44be26f0ea1aea82a6b0ed19668cae29a..b5ce865a4aaa2a4f37b4a6bc7c1cc9e0f48e0cb1 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print struct_padded_at_end
 // gdb-check:$5 = {x = {22, 23}, y = {24, 25}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print no_padding1
+// lldb-check:[...]$0 = NoPadding1 { x: [0, 1, 2], y: -3, z: [4.5, 5.5] }
+// lldb-command:print no_padding2
+// lldb-check:[...]$1 = NoPadding2 { x: [6, 7, 8], y: [[9, 10], [11, 12]] }
+
+// lldb-command:print struct_internal_padding
+// lldb-check:[...]$2 = StructInternalPadding { x: [13, 14], y: [15, 16] }
+
+// lldb-command:print single_vec
+// lldb-check:[...]$3 = SingleVec { x: [17, 18, 19, 20, 21] }
+
+// lldb-command:print struct_padded_at_end
+// lldb-check:[...]$4 = StructPaddedAtEnd { x: [22, 23], y: [24, 25] }
+
 #![allow(unused_variable)]
 
 struct NoPadding1 {
@@ -84,7 +106,7 @@ fn main() {
         y: [24, 25]
     };
 
-    zzz();
+    zzz(); // #break
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 535efa0b84efc8ce90c9f9da3852530f021db2b4..640e04cf71c11f1f72e3491bd1f8dbe3309fd774 100644 (file)
 
 // compile-flags:-g
 // gdb-command:set print pretty off
-// gdb-command:break function-arg-initialization.rs:139
-// gdb-command:break function-arg-initialization.rs:154
-// gdb-command:break function-arg-initialization.rs:158
-// gdb-command:break function-arg-initialization.rs:162
-// gdb-command:break function-arg-initialization.rs:166
-// gdb-command:break function-arg-initialization.rs:170
-// gdb-command:break function-arg-initialization.rs:174
-// gdb-command:break function-arg-initialization.rs:178
-// gdb-command:break function-arg-initialization.rs:182
-// gdb-command:break function-arg-initialization.rs:190
-// gdb-command:break function-arg-initialization.rs:197
-
+// gdb-command:break function-arg-initialization.rs:243
+// gdb-command:break function-arg-initialization.rs:258
+// gdb-command:break function-arg-initialization.rs:262
+// gdb-command:break function-arg-initialization.rs:266
+// gdb-command:break function-arg-initialization.rs:270
+// gdb-command:break function-arg-initialization.rs:274
+// gdb-command:break function-arg-initialization.rs:278
+// gdb-command:break function-arg-initialization.rs:282
+// gdb-command:break function-arg-initialization.rs:286
+// gdb-command:break function-arg-initialization.rs:294
+// gdb-command:break function-arg-initialization.rs:301
+
+// === GDB TESTS ===================================================================================
 
 // gdb-command:run
 
 // gdb-check:$32 = 45
 // gdb-command:continue
 
-#![allow(unused_variable)]
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// IMMEDIATE ARGS
+// lldb-command:print a
+// lldb-check:[...]$0 = 1
+// lldb-command:print b
+// lldb-check:[...]$1 = true
+// lldb-command:print c
+// lldb-check:[...]$2 = 2.5
+// lldb-command:continue
+
+// NON IMMEDIATE ARGS
+// lldb-command:print a
+// lldb-check:[...]$3 = BigStruct { a: 3, b: 4, c: 5, d: 6, e: 7, f: 8, g: 9, h: 10 }
+// lldb-command:print b
+// lldb-check:[...]$4 = BigStruct { a: 11, b: 12, c: 13, d: 14, e: 15, f: 16, g: 17, h: 18 }
+// lldb-command:continue
+
+// BINDING
+// lldb-command:print a
+// lldb-check:[...]$5 = 19
+// lldb-command:print b
+// lldb-check:[...]$6 = 20
+// lldb-command:print c
+// lldb-check:[...]$7 = 21.5
+// lldb-command:continue
+
+// ASSIGNMENT
+// lldb-command:print a
+// lldb-check:[...]$8 = 22
+// lldb-command:print b
+// lldb-check:[...]$9 = 23
+// lldb-command:print c
+// lldb-check:[...]$10 = 24.5
+// lldb-command:continue
+
+// FUNCTION CALL
+// lldb-command:print x
+// lldb-check:[...]$11 = 25
+// lldb-command:print y
+// lldb-check:[...]$12 = 26
+// lldb-command:print z
+// lldb-check:[...]$13 = 27.5
+// lldb-command:continue
+
+// EXPR
+// lldb-command:print x
+// lldb-check:[...]$14 = 28
+// lldb-command:print y
+// lldb-check:[...]$15 = 29
+// lldb-command:print z
+// lldb-check:[...]$16 = 30.5
+// lldb-command:continue
+
+// RETURN EXPR
+// lldb-command:print x
+// lldb-check:[...]$17 = 31
+// lldb-command:print y
+// lldb-check:[...]$18 = 32
+// lldb-command:print z
+// lldb-check:[...]$19 = 33.5
+// lldb-command:continue
+
+// ARITHMETIC EXPR
+// lldb-command:print x
+// lldb-check:[...]$20 = 34
+// lldb-command:print y
+// lldb-check:[...]$21 = 35
+// lldb-command:print z
+// lldb-check:[...]$22 = 36.5
+// lldb-command:continue
+
+// IF EXPR
+// lldb-command:print x
+// lldb-check:[...]$23 = 37
+// lldb-command:print y
+// lldb-check:[...]$24 = 38
+// lldb-command:print z
+// lldb-check:[...]$25 = 39.5
+// lldb-command:continue
+
+// WHILE EXPR
+// lldb-command:print x
+// lldb-check:[...]$26 = 40
+// lldb-command:print y
+// lldb-check:[...]$27 = 41
+// lldb-command:print z
+// lldb-check:[...]$28 = 42
+// lldb-command:continue
+
+// LOOP EXPR
+// lldb-command:print x
+// lldb-check:[...]$29 = 43
+// lldb-command:print y
+// lldb-check:[...]$30 = 44
+// lldb-command:print z
+// lldb-check:[...]$31 = 45
+// lldb-command:continue
+
+
+
+#![allow(unused_variable)]
 
 
 
 fn immediate_args(a: int, b: bool, c: f64) {
-    ()
+    () // #break
 }
 
 struct BigStruct {
@@ -151,35 +255,35 @@ struct BigStruct {
 }
 
 fn non_immediate_args(a: BigStruct, b: BigStruct) {
-    ()
+    () // #break
 }
 
 fn binding(a: i64, b: u64, c: f64) {
-    let x = 0i;
+    let x = 0i; // #break
 }
 
 fn assignment(mut a: u64, b: u64, c: f64) {
-    a = b;
+    a = b; // #break
 }
 
 fn function_call(x: u64, y: u64, z: f64) {
-    std::io::stdio::print("Hi!")
+    std::io::stdio::print("Hi!") // #break
 }
 
 fn identifier(x: u64, y: u64, z: f64) -> u64 {
-    x
+    x // #break
 }
 
 fn return_expr(x: u64, y: u64, z: f64) -> u64 {
-    return x;
+    return x; // #break
 }
 
 fn arithmetic_expr(x: u64, y: u64, z: f64) -> u64 {
-    x + y
+    x + y // #break
 }
 
 fn if_expr(x: u64, y: u64, z: f64) -> u64 {
-    if x + y < 1000 {
+    if x + y < 1000 { // #break
         x
     } else {
         y
@@ -187,14 +291,14 @@ fn if_expr(x: u64, y: u64, z: f64) -> u64 {
 }
 
 fn while_expr(mut x: u64, y: u64, z: u64) -> u64 {
-    while x + y < 1000 {
+    while x + y > 1000 { // #break
         x += z
     }
     return x;
 }
 
 fn loop_expr(mut x: u64, y: u64, z: u64) -> u64 {
-    loop {
+    loop { // #break
         x += z;
 
         if x + y > 1000 {
index e65b9a2519d60259bd3e27e335e9b53cdb6920e9..69bd5ae1d6c30af43d4eca3bea296775ffd151e4 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print b
 // gdb-check:$4 = 3000
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = 111102
+// lldb-command:print y
+// lldb-check:[...]$1 = true
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$2 = 2000
+// lldb-command:print b
+// lldb-check:[...]$3 = 3000
+// lldb-command:continue
+
 fn main() {
 
     fun(111102, true);
     nested(2000, 3000);
 
     fn nested(a: i32, b: i64) -> (i32, i64) {
-        zzz();
+        zzz(); // #break
         (a, b)
     }
 }
 
 fn fun(x: int, y: bool) -> (int, bool) {
-    zzz();
+    zzz(); // #break
 
     (x, y)
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 0160a6f1879dbe3706d2d4db0cf67f161d7b6157..05e2c5eb6c7ca84ad916494998331a4039479d7a 100644 (file)
 // beginning of a function. Functions with the #[no_split_stack] attribute have the same prologue as
 // regular C functions compiled with GCC or Clang and therefore are better handled by GDB. As a
 // consequence, and as opposed to regular Rust functions, we can set the breakpoints via the
-// function name (and don't have to fall back on using line numbers).
+// function name (and don't have to fall back on using line numbers). For LLDB this shouldn't make
+// a difference because it can handle both cases.
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak immediate_args
 // gdb-command:rbreak binding
 // gdb-check:$32 = 45
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:breakpoint set --name immediate_args
+// lldb-command:breakpoint set --name non_immediate_args
+// lldb-command:breakpoint set --name binding
+// lldb-command:breakpoint set --name assignment
+// lldb-command:breakpoint set --name function_call
+// lldb-command:breakpoint set --name identifier
+// lldb-command:breakpoint set --name return_expr
+// lldb-command:breakpoint set --name arithmetic_expr
+// lldb-command:breakpoint set --name if_expr
+// lldb-command:breakpoint set --name while_expr
+// lldb-command:breakpoint set --name loop_expr
+// lldb-command:run
+
+// IMMEDIATE ARGS
+// lldb-command:print a
+// lldb-check:[...]$0 = 1
+// lldb-command:print b
+// lldb-check:[...]$1 = true
+// lldb-command:print c
+// lldb-check:[...]$2 = 2.5
+// lldb-command:continue
+
+// NON IMMEDIATE ARGS
+// lldb-command:print a
+// lldb-check:[...]$3 = BigStruct { a: 3, b: 4, c: 5, d: 6, e: 7, f: 8, g: 9, h: 10 }
+// lldb-command:print b
+// lldb-check:[...]$4 = BigStruct { a: 11, b: 12, c: 13, d: 14, e: 15, f: 16, g: 17, h: 18 }
+// lldb-command:continue
+
+// BINDING
+// lldb-command:print a
+// lldb-check:[...]$5 = 19
+// lldb-command:print b
+// lldb-check:[...]$6 = 20
+// lldb-command:print c
+// lldb-check:[...]$7 = 21.5
+// lldb-command:continue
+
+// ASSIGNMENT
+// lldb-command:print a
+// lldb-check:[...]$8 = 22
+// lldb-command:print b
+// lldb-check:[...]$9 = 23
+// lldb-command:print c
+// lldb-check:[...]$10 = 24.5
+// lldb-command:continue
+
+// FUNCTION CALL
+// lldb-command:print x
+// lldb-check:[...]$11 = 25
+// lldb-command:print y
+// lldb-check:[...]$12 = 26
+// lldb-command:print z
+// lldb-check:[...]$13 = 27.5
+// lldb-command:continue
+
+// EXPR
+// lldb-command:print x
+// lldb-check:[...]$14 = 28
+// lldb-command:print y
+// lldb-check:[...]$15 = 29
+// lldb-command:print z
+// lldb-check:[...]$16 = 30.5
+// lldb-command:continue
+
+// RETURN EXPR
+// lldb-command:print x
+// lldb-check:[...]$17 = 31
+// lldb-command:print y
+// lldb-check:[...]$18 = 32
+// lldb-command:print z
+// lldb-check:[...]$19 = 33.5
+// lldb-command:continue
+
+// ARITHMETIC EXPR
+// lldb-command:print x
+// lldb-check:[...]$20 = 34
+// lldb-command:print y
+// lldb-check:[...]$21 = 35
+// lldb-command:print z
+// lldb-check:[...]$22 = 36.5
+// lldb-command:continue
+
+// IF EXPR
+// lldb-command:print x
+// lldb-check:[...]$23 = 37
+// lldb-command:print y
+// lldb-check:[...]$24 = 38
+// lldb-command:print z
+// lldb-check:[...]$25 = 39.5
+// lldb-command:continue
+
+// WHILE EXPR
+// lldb-command:print x
+// lldb-check:[...]$26 = 40
+// lldb-command:print y
+// lldb-check:[...]$27 = 41
+// lldb-command:print z
+// lldb-check:[...]$28 = 42
+// lldb-command:continue
+
+// LOOP EXPR
+// lldb-command:print x
+// lldb-check:[...]$29 = 43
+// lldb-command:print y
+// lldb-check:[...]$30 = 44
+// lldb-command:print z
+// lldb-check:[...]$31 = 45
+// lldb-command:continue
+
 #![allow(unused_variable)]
 
 #[no_split_stack]
diff --git a/src/test/debuginfo/function-prologue-stepping-regular.rs b/src/test/debuginfo/function-prologue-stepping-regular.rs
new file mode 100644 (file)
index 0000000..7cb9c6b
--- /dev/null
@@ -0,0 +1,232 @@
+// Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+// This test case checks if function arguments already have the correct value when breaking at the
+// beginning of a function.
+
+// ignore-gdb
+// compile-flags:-g
+
+// lldb-command:breakpoint set --name immediate_args
+// lldb-command:breakpoint set --name non_immediate_args
+// lldb-command:breakpoint set --name binding
+// lldb-command:breakpoint set --name assignment
+// lldb-command:breakpoint set --name function_call
+// lldb-command:breakpoint set --name identifier
+// lldb-command:breakpoint set --name return_expr
+// lldb-command:breakpoint set --name arithmetic_expr
+// lldb-command:breakpoint set --name if_expr
+// lldb-command:breakpoint set --name while_expr
+// lldb-command:breakpoint set --name loop_expr
+// lldb-command:run
+
+// IMMEDIATE ARGS
+// lldb-command:print a
+// lldb-check:[...]$0 = 1
+// lldb-command:print b
+// lldb-check:[...]$1 = true
+// lldb-command:print c
+// lldb-check:[...]$2 = 2.5
+// lldb-command:continue
+
+// NON IMMEDIATE ARGS
+// lldb-command:print a
+// lldb-check:[...]$3 = BigStruct { a: 3, b: 4, c: 5, d: 6, e: 7, f: 8, g: 9, h: 10 }
+// lldb-command:print b
+// lldb-check:[...]$4 = BigStruct { a: 11, b: 12, c: 13, d: 14, e: 15, f: 16, g: 17, h: 18 }
+// lldb-command:continue
+
+// BINDING
+// lldb-command:print a
+// lldb-check:[...]$5 = 19
+// lldb-command:print b
+// lldb-check:[...]$6 = 20
+// lldb-command:print c
+// lldb-check:[...]$7 = 21.5
+// lldb-command:continue
+
+// ASSIGNMENT
+// lldb-command:print a
+// lldb-check:[...]$8 = 22
+// lldb-command:print b
+// lldb-check:[...]$9 = 23
+// lldb-command:print c
+// lldb-check:[...]$10 = 24.5
+// lldb-command:continue
+
+// FUNCTION CALL
+// lldb-command:print x
+// lldb-check:[...]$11 = 25
+// lldb-command:print y
+// lldb-check:[...]$12 = 26
+// lldb-command:print z
+// lldb-check:[...]$13 = 27.5
+// lldb-command:continue
+
+// EXPR
+// lldb-command:print x
+// lldb-check:[...]$14 = 28
+// lldb-command:print y
+// lldb-check:[...]$15 = 29
+// lldb-command:print z
+// lldb-check:[...]$16 = 30.5
+// lldb-command:continue
+
+// RETURN EXPR
+// lldb-command:print x
+// lldb-check:[...]$17 = 31
+// lldb-command:print y
+// lldb-check:[...]$18 = 32
+// lldb-command:print z
+// lldb-check:[...]$19 = 33.5
+// lldb-command:continue
+
+// ARITHMETIC EXPR
+// lldb-command:print x
+// lldb-check:[...]$20 = 34
+// lldb-command:print y
+// lldb-check:[...]$21 = 35
+// lldb-command:print z
+// lldb-check:[...]$22 = 36.5
+// lldb-command:continue
+
+// IF EXPR
+// lldb-command:print x
+// lldb-check:[...]$23 = 37
+// lldb-command:print y
+// lldb-check:[...]$24 = 38
+// lldb-command:print z
+// lldb-check:[...]$25 = 39.5
+// lldb-command:continue
+
+// WHILE EXPR
+// lldb-command:print x
+// lldb-check:[...]$26 = 40
+// lldb-command:print y
+// lldb-check:[...]$27 = 41
+// lldb-command:print z
+// lldb-check:[...]$28 = 42
+// lldb-command:continue
+
+// LOOP EXPR
+// lldb-command:print x
+// lldb-check:[...]$29 = 43
+// lldb-command:print y
+// lldb-check:[...]$30 = 44
+// lldb-command:print z
+// lldb-check:[...]$31 = 45
+// lldb-command:continue
+
+#![allow(unused_variable)]
+
+fn immediate_args(a: int, b: bool, c: f64) {
+    ()
+}
+
+struct BigStruct {
+    a: u64,
+    b: u64,
+    c: u64,
+    d: u64,
+    e: u64,
+    f: u64,
+    g: u64,
+    h: u64
+}
+
+fn non_immediate_args(a: BigStruct, b: BigStruct) {
+    ()
+}
+
+fn binding(a: i64, b: u64, c: f64) {
+    let x = 0i;
+}
+
+fn assignment(mut a: u64, b: u64, c: f64) {
+    a = b;
+}
+
+fn function_call(x: u64, y: u64, z: f64) {
+    std::io::stdio::print("Hi!")
+}
+
+fn identifier(x: u64, y: u64, z: f64) -> u64 {
+    x
+}
+
+fn return_expr(x: u64, y: u64, z: f64) -> u64 {
+    return x;
+}
+
+fn arithmetic_expr(x: u64, y: u64, z: f64) -> u64 {
+    x + y
+}
+
+fn if_expr(x: u64, y: u64, z: f64) -> u64 {
+    if x + y < 1000 {
+        x
+    } else {
+        y
+    }
+}
+
+fn while_expr(mut x: u64, y: u64, z: u64) -> u64 {
+    while x + y < 1000 {
+        x += z
+    }
+    return x;
+}
+
+fn loop_expr(mut x: u64, y: u64, z: u64) -> u64 {
+    loop {
+        x += z;
+
+        if x + y > 1000 {
+            return x;
+        }
+    }
+}
+
+fn main() {
+    immediate_args(1, true, 2.5);
+
+    non_immediate_args(
+        BigStruct {
+            a: 3,
+            b: 4,
+            c: 5,
+            d: 6,
+            e: 7,
+            f: 8,
+            g: 9,
+            h: 10
+        },
+        BigStruct {
+            a: 11,
+            b: 12,
+            c: 13,
+            d: 14,
+            e: 15,
+            f: 16,
+            g: 17,
+            h: 18
+        }
+    );
+
+    binding(19, 20, 21.5);
+    assignment(22, 23, 24.5);
+    function_call(25, 26, 27.5);
+    identifier(28, 29, 30.5);
+    return_expr(31, 32, 33.5);
+    arithmetic_expr(34, 35, 36.5);
+    if_expr(37, 38, 39.5);
+    while_expr(40, 41, 42);
+    loop_expr(43, 44, 45);
+}
index 1777c168d9b9a49989252854e0be1ada323e98a1..c3996929e7c79ae748b0451c977c2893eea7ebeb 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$9 = {{5, {a = 6, b = 7.5}}, {{a = 6, b = 7.5}, 5}}
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *t0
+// lldb-check:[...]$0 = 1
+// lldb-command:print *t1
+// lldb-check:[...]$1 = 2.5
+// lldb-command:print ret
+// lldb-check:[...]$2 = ((1, 2.5), (2.5, 1))
+// lldb-command:continue
+
+// lldb-command:print *t0
+// lldb-check:[...]$3 = 3.5
+// lldb-command:print *t1
+// lldb-check:[...]$4 = 4
+// lldb-command:print ret
+// lldb-check:[...]$5 = ((3.5, 4), (4, 3.5))
+// lldb-command:continue
+
+// lldb-command:print *t0
+// lldb-check:[...]$6 = 5
+// lldb-command:print *t1
+// lldb-check:[...]$7 = Struct { a: 6, b: 7.5 }
+// lldb-command:print ret
+// lldb-check:[...]$8 = ((5, Struct { a: 6, b: 7.5 }), (Struct { a: 6, b: 7.5 }, 5))
+// lldb-command:continue
+
+
 #[deriving(Clone)]
 struct Struct {
     a: int,
@@ -49,7 +82,7 @@ struct Struct {
 
 fn dup_tup<T0: Clone, T1: Clone>(t0: &T0, t1: &T1) -> ((T0, T1), (T1, T0)) {
     let ret = ((t0.clone(), t1.clone()), (t1.clone(), t0.clone()));
-    zzz();
+    zzz(); // #break
     ret
 }
 
index 1805405dc1ef5d16522e13edf6f1e711e2a175ee..2546c2c233954b881f39a20d582e626d1b83cc51 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$8 = 2.5
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = -1
+// lldb-command:print y
+// lldb-check:[...]$1 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = -1
+// lldb-command:print y
+// lldb-check:[...]$3 = 2.5
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = -2.5
+// lldb-command:print y
+// lldb-check:[...]$5 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$6 = -2.5
+// lldb-command:print y
+// lldb-check:[...]$7 = 2.5
+// lldb-command:continue
+
 fn outer<TA: Clone>(a: TA) {
     inner(a.clone(), 1i);
     inner(a.clone(), 2.5f64);
 
     fn inner<TX, TY>(x: TX, y: TY) {
-        zzz();
+        zzz(); // #break
     }
 }
 
@@ -56,4 +88,4 @@ fn main() {
     outer(-2.5f64);
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 9ed1c0175a91b50cea50abee50f17e385f74e7b1..0f05eea62821318510363eb4f2580b5ff326f38b 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
@@ -20,8 +23,8 @@
 // gdb-check:$1 = {x = {8888, -8888}}
 // gdb-command:print arg1
 // gdb-check:$2 = -1
-// gdb-command:print/d arg2
-// gdb-check:$3 = -2
+// gdb-command:print arg2
+// gdb-check:$3 = 2
 // gdb-command:continue
 
 // STACK BY VAL
 // gdb-check:$15 = -10.5
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Struct<(u32, i32)> { x: (8888, -8888) }
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = 2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Struct<(u32, i32)> { x: (8888, -8888) }
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Struct<f64> { x: 1234.5 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Struct<f64> { x: 1234.5 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Struct<f64> { x: 1234.5 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10.5
+// lldb-command:continue
+
+
 struct Struct<T> {
     x: T
 }
@@ -71,24 +125,24 @@ struct Struct<T> {
 impl<T1> Struct<T1> {
 
     fn self_by_ref<T2>(&self, arg1: int, arg2: T2) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 
     fn self_by_val<T2>(self, arg1: int, arg2: T2) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 
     fn self_owned<T2>(~self, arg1: int, arg2: T2) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 }
 
 fn main() {
     let stack = Struct { x: (8888_u32, -8888_i32) };
-    let _ = stack.self_by_ref(-1, -2_i8);
+    let _ = stack.self_by_ref(-1, 2_u16);
     let _ = stack.self_by_val(-3, -4_i16);
 
     let owned = box Struct { x: 1234.5f64 };
index a2c5a0973fca4f2f6bd25c6fc6301393331a7d8c..65ccb1314add3647c50eed75f2f989c6128737f8 100644 (file)
@@ -8,9 +8,13 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// ignore-tidy-linelength
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-command:print float_int_float
 // gdb-check:$4 = {key = 6.5, value = {key = 7, value = 8.5}}
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print int_int
+// lldb-check:[...]$0 = AGenericStruct<int, int> { key: 0, value: 1 }
+// lldb-command:print int_float
+// lldb-check:[...]$1 = AGenericStruct<int, f64> { key: 2, value: 3.5 }
+// lldb-command:print float_int
+// lldb-check:[...]$2 = AGenericStruct<f64, int> { key: 4.5, value: 5 }
+
+// lldb-command:print float_int_float
+// lldb-check:[...]$3 = AGenericStruct<f64, generic-struct::AGenericStruct<int, f64>> { key: 6.5, value: AGenericStruct<int, f64> { key: 7, value: 8.5 } }
+
 struct AGenericStruct<TKey, TValue> {
     key: TKey,
     value: TValue
@@ -39,7 +57,7 @@ fn main() {
         value: AGenericStruct { key: 7i, value: 8.5f64 },
     };
 
-    zzz();
+    zzz(); // #break
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 07f7546068ca9f7fc12125638e26c221b1c20e0a..8638ae3b49d890c58bfb5571ed3ad73c323c8063 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print union on
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-check:$4 = {{-1}}
 
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print case1
+// lldb-check:[...]$0 = Case1(0, 31868, 31868, 31868, 31868)
+
+// lldb-command:print case2
+// lldb-check:[...]$1 = Case2(0, 286331153, 286331153)
+
+// lldb-command:print case3
+// lldb-check:[...]$2 = Case3(0, 6438275382588823897)
+
+// lldb-command:print univariant
+// lldb-check:[...]$3 = TheOnlyCase(-1)
+
+
 // NOTE: This is a copy of the non-generic test case. The `Txx` type parameters have to be
 // substituted with something of size `xx` bits and the same alignment as an integer type of the
 // same size.
@@ -73,7 +93,7 @@ fn main() {
 
     let univariant = TheOnlyCase(-1_i64);
 
-    zzz();
+    zzz(); // #break
 }
 
-fn zzz() {()}
+fn zzz() { () }
index 977e304a32ec235dc6c4b67b901b0931adfa6c1c..ed9767c78f3f609e415e6504caacf32ac2f11bad 100644 (file)
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print string1.length
-// gdb-check:$1 = 49
+// gdb-check:$1 = 48
 // gdb-command:print string2.length
 // gdb-check:$2 = 49
 // gdb-command:print string3.length
-// gdb-check:$3 = 49
+// gdb-check:$3 = 50
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print string1.length
+// lldb-check:[...]$0 = 48
+// lldb-command:print string2.length
+// lldb-check:[...]$1 = 49
+// lldb-command:print string3.length
+// lldb-check:[...]$2 = 50
+
+// lldb-command:continue
+
 #![allow(unused_variable)]
 
 // This test case makes sure that debug info does not ICE when include_str is
@@ -31,7 +45,8 @@ fn main() {
     let string1 = include_str!("text-to-include-1.txt");
     let string2 = include_str!("text-to-include-2.txt");
     let string3 = include_str!("text-to-include-3.txt");
-    zzz();
+
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 0fb823a74cc72c11ba27d7c2e828bc60b27b71c2..13cae3252d804e90762baf4c0cdce002d090ca60 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$7 = 1000000
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// FIRST ITERATION
+// lldb-command:print x
+// lldb-check:[...]$0 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = -1
+// lldb-command:continue
+
+// SECOND ITERATION
+// lldb-command:print x
+// lldb-check:[...]$2 = 2
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$3 = -2
+// lldb-command:continue
+
+// THIRD ITERATION
+// lldb-command:print x
+// lldb-check:[...]$4 = 3
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$5 = -3
+// lldb-command:continue
+
+// AFTER LOOP
+// lldb-command:print x
+// lldb-check:[...]$6 = 1000000
+// lldb-command:continue
+
 fn main() {
 
     let range = [1i, 2, 3];
@@ -60,16 +100,16 @@ fn main() {
     let x = 1000000i; // wan meeeljen doollaars!
 
     for &x in range.iter() {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = -1i * x;
 
-        zzz();
+        zzz(); // #break
         sentinel();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 6018e62af0078db154ffa225d47e02f3b1355deb..ce30886c7d375aa4aa1cc3eaac0f164708d657fe 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$16 = -1
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// BEFORE if
+// lldb-command:print x
+// lldb-check:[...]$0 = 999
+// lldb-command:print y
+// lldb-check:[...]$1 = -1
+// lldb-command:continue
+
+// AT BEGINNING of 'then' block
+// lldb-command:print x
+// lldb-check:[...]$2 = 999
+// lldb-command:print y
+// lldb-check:[...]$3 = -1
+// lldb-command:continue
+
+// AFTER 1st redeclaration of 'x'
+// lldb-command:print x
+// lldb-check:[...]$4 = 1001
+// lldb-command:print y
+// lldb-check:[...]$5 = -1
+// lldb-command:continue
+
+// AFTER 2st redeclaration of 'x'
+// lldb-command:print x
+// lldb-check:[...]$6 = 1002
+// lldb-command:print y
+// lldb-check:[...]$7 = 1003
+// lldb-command:continue
+
+// AFTER 1st if expression
+// lldb-command:print x
+// lldb-check:[...]$8 = 999
+// lldb-command:print y
+// lldb-check:[...]$9 = -1
+// lldb-command:continue
+
+// BEGINNING of else branch
+// lldb-command:print x
+// lldb-check:[...]$10 = 999
+// lldb-command:print y
+// lldb-check:[...]$11 = -1
+// lldb-command:continue
+
+// BEGINNING of else branch
+// lldb-command:print x
+// lldb-check:[...]$12 = 1004
+// lldb-command:print y
+// lldb-check:[...]$13 = 1005
+// lldb-command:continue
+
+// BEGINNING of else branch
+// lldb-command:print x
+// lldb-check:[...]$14 = 999
+// lldb-command:print y
+// lldb-check:[...]$15 = -1
+// lldb-command:continue
+
+
 fn main() {
 
     let x = 999i;
     let y = -1i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     if x < 1000 {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 1001i;
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 1002i;
         let y = 1003i;
-        zzz();
+        zzz(); // #break
         sentinel();
     } else {
         unreachable!();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     if x > 1000 {
         unreachable!();
     } else {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 1004i;
         let y = 1005i;
-        zzz();
+        zzz(); // #break
         sentinel();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 7bec677e4b1005b9e379aa2e69f06011c6967121..78e9b278e53a9c1c701157b6d20341eefd327528 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$18 = 232
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print shadowed
+// lldb-check:[...]$0 = 231
+// lldb-command:print not_shadowed
+// lldb-check:[...]$1 = 232
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$2 = 233
+// lldb-command:print not_shadowed
+// lldb-check:[...]$3 = 232
+// lldb-command:print local_to_arm
+// lldb-check:[...]$4 = 234
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$5 = 236
+// lldb-command:print not_shadowed
+// lldb-check:[...]$6 = 232
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$7 = 237
+// lldb-command:print not_shadowed
+// lldb-check:[...]$8 = 232
+// lldb-command:print local_to_arm
+// lldb-check:[...]$9 = 238
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$10 = 239
+// lldb-command:print not_shadowed
+// lldb-check:[...]$11 = 232
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$12 = 241
+// lldb-command:print not_shadowed
+// lldb-check:[...]$13 = 232
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$14 = 243
+// lldb-command:print *local_to_arm
+// lldb-check:[...]$15 = 244
+// lldb-command:continue
+
+// lldb-command:print shadowed
+// lldb-check:[...]$16 = 231
+// lldb-command:print not_shadowed
+// lldb-check:[...]$17 = 232
+// lldb-command:continue
+
+
 struct Struct {
     x: int,
     y: int
@@ -84,13 +145,13 @@ fn main() {
     let shadowed = 231i;
     let not_shadowed = 232i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     match (233i, 234i) {
         (shadowed, local_to_arm) => {
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
     }
@@ -99,7 +160,7 @@ fn main() {
         // with literal
         (235, shadowed) => {
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
         _ => {}
@@ -108,7 +169,7 @@ fn main() {
     match (Struct { x: 237, y: 238 }) {
         Struct { x: shadowed, y: local_to_arm } => {
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
     }
@@ -117,7 +178,7 @@ fn main() {
         // ignored field
         Struct { x: shadowed, .. } => {
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
     }
@@ -126,7 +187,7 @@ fn main() {
         // with literal
         Struct { x: shadowed, y: 242 } => {
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
         _ => {}
@@ -135,12 +196,12 @@ fn main() {
     match (243i, 244i) {
         (shadowed, ref local_to_arm) => {
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 0168eaa86c2d1d90d2647113c21a688717e49b07..aca6cc06abddb6f55d48bce5eec64e1d16bdf3e7 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$6 = false
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = false
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = false
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 1000
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$3 = 2.5
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$5 = false
+// lldb-command:continue
+
 fn main() {
 
     let x = false;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let stack_closure: |int| = |x| {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 2.5f64;
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = true;
 
-        zzz();
+        zzz(); // #break
         sentinel();
     };
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     stack_closure(1000);
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 48edd7ae12a096f4bdcd81659626c6948e510feb..3096dfbd2a6e201c357bbd4c611108beb864223b 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$13 = 2
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// FIRST ITERATION
+// lldb-command:print x
+// lldb-check:[...]$0 = 0
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 101
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$3 = 101
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = -987
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$5 = 101
+// lldb-command:continue
+
+
+// SECOND ITERATION
+// lldb-command:print x
+// lldb-check:[...]$6 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$7 = 2
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$8 = 102
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$9 = 102
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$10 = -987
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$11 = 102
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$12 = 2
+// lldb-command:continue
+
 fn main() {
 
     let mut x = 0i;
@@ -91,35 +154,35 @@ fn main() {
             break;
         }
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         x += 1;
-        zzz();
+        zzz(); // #break
         sentinel();
 
         // Shadow x
         let x = x + 100;
-        zzz();
+        zzz(); // #break
         sentinel();
 
         // open scope within loop's top level scope
         {
-            zzz();
+            zzz(); // #break
             sentinel();
 
             let x = -987i;
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
 
         // Check that we get the x before the inner scope again
-        zzz();
+        zzz(); // #break
         sentinel();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index ce3b2a530e2c297f38096d3ab075944c6a8777c3..590b7238c123a0a5f0e1f9e500c127d0c9ecfe2a 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$6 = false
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = false
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = false
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 1000
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$3 = 2.5
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$5 = false
+// lldb-command:continue
+
 fn main() {
 
     let x = false;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let unique_closure: proc(int) = proc(x) {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 2.5f64;
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = true;
 
-        zzz();
+        zzz(); // #break
         sentinel();
     };
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     unique_closure(1000);
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index d726eb6581eb2cd9778903ae570f65d29ea3fb81..b211c11128a7ce9f680aa9832bdf531683fe01c3 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$13 = 2
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// FIRST ITERATION
+// lldb-command:print x
+// lldb-check:[...]$0 = 0
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 101
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$3 = 101
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = -987
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$5 = 101
+// lldb-command:continue
+
+
+// SECOND ITERATION
+// lldb-command:print x
+// lldb-check:[...]$6 = 1
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$7 = 2
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$8 = 102
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$9 = 102
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$10 = -987
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$11 = 102
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$12 = 2
+// lldb-command:continue
+
+
 fn main() {
 
     let mut x = 0i;
 
     while x < 2 {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         x += 1;
-        zzz();
+        zzz(); // #break
         sentinel();
 
         // Shadow x
         let x = x + 100;
-        zzz();
+        zzz(); // #break
         sentinel();
 
         // open scope within loop's top level scope
         {
-            zzz();
+            zzz(); // #break
             sentinel();
 
             let x = -987i;
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
 
         // Check that we get the x before the inner scope again
-        zzz();
+        zzz(); // #break
         sentinel();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index e55271239d488bbf88fadb09e10ba0aaa7450242..27070dd867d0e40458ff6d3812271cc77820fb4d 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = 400
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print a
+// lldb-check:[...]$0 = 10
+// lldb-command:print b
+// lldb-check:[...]$1 = 34
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$2 = 890242
+// lldb-command:print b
+// lldb-check:[...]$3 = 34
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$4 = 10
+// lldb-command:print b
+// lldb-check:[...]$5 = 34
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$6 = 102
+// lldb-command:print b
+// lldb-check:[...]$7 = 34
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$8 = 110
+// lldb-command:print b
+// lldb-check:[...]$9 = 34
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$10 = 10
+// lldb-command:print b
+// lldb-check:[...]$11 = 34
+// lldb-command:continue
+
+// lldb-command:print a
+// lldb-check:[...]$12 = 10
+// lldb-command:print b
+// lldb-check:[...]$13 = 34
+// lldb-command:print c
+// lldb-check:[...]$14 = 400
+// lldb-command:continue
+
+
 #![feature(macro_rules)]
 
 macro_rules! trivial(
@@ -78,7 +131,7 @@ macro_rules! no_new_scope(
 macro_rules! new_scope(
     () => ({
         let a = 890242i;
-        zzz();
+        zzz(); // #break
         sentinel();
     })
 )
@@ -87,12 +140,12 @@ macro_rules! shadow_within_macro(
     ($e1:expr) => ({
         let a = $e1 + 2;
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let a = $e1 + 10;
 
-        zzz();
+        zzz(); // #break
         sentinel();
     })
 )
@@ -108,22 +161,22 @@ fn main() {
     let a = trivial!(10i);
     let b = no_new_scope!(33i);
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     new_scope!();
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     shadow_within_macro!(100i);
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let c = dup_expr!(10i * 20);
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 2a9969dc6e90310e42fd6466dd2bec61a365dbab..b5f9622e79a7bd977aaab5e63ee4c0e41bca8f8a 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$57 = 10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STRUCT EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$0 = -1
+// lldb-command:print ten
+// lldb-check:[...]$1 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$2 = 11
+// lldb-command:print ten
+// lldb-check:[...]$3 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$4 = -1
+// lldb-command:print ten
+// lldb-check:[...]$5 = 10
+// lldb-command:continue
+
+// FUNCTION CALL
+// lldb-command:print val
+// lldb-check:[...]$6 = -1
+// lldb-command:print ten
+// lldb-check:[...]$7 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$8 = 12
+// lldb-command:print ten
+// lldb-check:[...]$9 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$10 = -1
+// lldb-command:print ten
+// lldb-check:[...]$11 = 10
+// lldb-command:continue
+
+// TUPLE EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$12 = -1
+// lldb-command:print ten
+// lldb-check:[...]$13 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$14 = 13
+// lldb-command:print ten
+// lldb-check:[...]$15 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$16 = -1
+// lldb-command:print ten
+// lldb-check:[...]$17 = 10
+// lldb-command:continue
+
+// VEC EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$18 = -1
+// lldb-command:print ten
+// lldb-check:[...]$19 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$20 = 14
+// lldb-command:print ten
+// lldb-check:[...]$21 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$22 = -1
+// lldb-command:print ten
+// lldb-check:[...]$23 = 10
+// lldb-command:continue
+
+// REPEAT VEC EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$24 = -1
+// lldb-command:print ten
+// lldb-check:[...]$25 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$26 = 15
+// lldb-command:print ten
+// lldb-check:[...]$27 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$28 = -1
+// lldb-command:print ten
+// lldb-check:[...]$29 = 10
+// lldb-command:continue
+
+// ASSIGNMENT EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$30 = -1
+// lldb-command:print ten
+// lldb-check:[...]$31 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$32 = 16
+// lldb-command:print ten
+// lldb-check:[...]$33 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$34 = -1
+// lldb-command:print ten
+// lldb-check:[...]$35 = 10
+// lldb-command:continue
+
+
+// ARITHMETIC EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$36 = -1
+// lldb-command:print ten
+// lldb-check:[...]$37 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$38 = 17
+// lldb-command:print ten
+// lldb-check:[...]$39 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$40 = -1
+// lldb-command:print ten
+// lldb-check:[...]$41 = 10
+// lldb-command:continue
+
+// INDEX EXPRESSION
+// lldb-command:print val
+// lldb-check:[...]$42 = -1
+// lldb-command:print ten
+// lldb-check:[...]$43 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$44 = 18
+// lldb-command:print ten
+// lldb-check:[...]$45 = 10
+// lldb-command:continue
+
+// lldb-command:print val
+// lldb-check:[...]$46 = -1
+// lldb-command:print ten
+// lldb-check:[...]$47 = 10
+// lldb-command:continue
+
 #![allow(unused_variable)]
 #![allow(dead_assignment)]
 
@@ -233,13 +394,13 @@ fn main() {
     // surrounded by struct expression
     let point = Point {
         x: {
-            zzz();
+            zzz(); // #break
             sentinel();
 
             let val = ten + 1;
             unsafe {MUT_INT = 1;};
 
-            zzz();
+            zzz(); // #break
             sentinel();
 
             val
@@ -247,129 +408,129 @@ fn main() {
         y: 10
     };
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     // surrounded by function call
     let _ = a_function({
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 2;
         unsafe {MUT_INT = 2;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val
     });
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
 
     // surrounded by tup
     let _ = ({
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 3;
         unsafe {MUT_INT = 3;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val
     }, 0i);
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     // surrounded by vec
     let _ = [{
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 4;
         unsafe {MUT_INT = 4;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val
     }, 0, 0];
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     // surrounded by repeat vec
     let _ = [{
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 5;
         unsafe {MUT_INT = 5;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val
     }, ..10];
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     // assignment expression
     let mut var = 0;
     var = {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 6;
         unsafe {MUT_INT = 6;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val
     };
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     // arithmetic expression
     var = 10 + -{
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 7;
         unsafe {MUT_INT = 7;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val
     } * 5;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     // index expression
     let a_vector = [10i, ..20];
     let _ = a_vector[{
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let val = ten + 8;
         unsafe {MUT_INT = 8;};
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         val as uint
     }];
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 9cda2c45131db1f4e7ae770f6d0738acc2c8c9e2..6c71971a0f82406525053b0c874d698da3958135 100644 (file)
@@ -10,6 +10,8 @@
 
 // ignore-android: FIXME(#10381)
 
+// ignore-lldb
+
 // compile-flags:--debuginfo=1
 
 // Make sure functions have proper names
index bb236a28a88008ce8f598ad141311be59c0e6695..2fd43d3e9ca67a1e36b53bae229697373e96401e 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print univariant->val
 // gdb-check:$3 = {{-9747455}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print the_a->val
+// lldb-check:[...]$0 = TheA { x: 0, y: 8970181431921507452 }
+
+// lldb-command:print the_b->val
+// lldb-check:[...]$1 = TheB(0, 286331153, 286331153)
+
+// lldb-command:print univariant->val
+// lldb-check:[...]$2 = TheOnlyCase(-9747455)
+
 #![allow(unused_variable)]
 #![feature(struct_variant, managed_boxes)]
 
@@ -62,7 +79,7 @@ fn main() {
 
     let univariant = box(GC) TheOnlyCase(-9747455);
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index d1f38be1d8947c2807756962089f93d65cd18ab2..6abd174b1aa67e164c8517bd3f799363e5d4da71 100644 (file)
@@ -13,6 +13,9 @@
 #![feature(managed_boxes)]
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print unique.ptr[3]->val
 // gdb-check:$4 = 13
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print unique.ptr[0]->val
+// lldb-check:[...]$0 = 10
+
+// lldb-command:print unique.ptr[1]->val
+// lldb-check:[...]$1 = 11
+
+// lldb-command:print unique.ptr[2]->val
+// lldb-check:[...]$2 = 12
+
+// lldb-command:print unique.ptr[3]->val
+// lldb-check:[...]$3 = 13
+
+
 #![allow(unused_variable)]
 
 use std::gc::{Gc, GC};
@@ -37,7 +58,7 @@ fn main() {
 
     let unique: Vec<Gc<i64>> = vec!(box(GC) 10, box(GC) 11, box(GC) 12, box(GC) 13);
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index cc18ea64f383eeedeb74cbd18cf239ac3b66632a..7f1b32936c8197c8fcfe7065cf2e6bab72f5cc64 100644 (file)
@@ -13,6 +13,9 @@
 #![feature(managed_boxes)]
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print managed_within_unique->y->val
 // gdb-check:$3 = -4
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *ordinary_unique
+// lldb-check:[...]$0 = (-1, -2)
+
+// lldb-command:print managed_within_unique->x
+// lldb-check:[...]$1 = -3
+
+// lldb-command:print managed_within_unique->y->val
+// lldb-check:[...]$2 = -4
+
 #![allow(unused_variable)]
 
 use std::gc::{GC, Gc};
@@ -41,7 +57,7 @@ fn main() {
 
     let managed_within_unique = box ContainsManaged { x: -3, y: box(GC) -4i };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 1a5fac18a6973b6405bf19e50e65071536d9dd24..f3d723e88bc515d6bc0f11d3ffd15835247b7048 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = -10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Variant2(117901063)
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = -2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Variant2(117901063)
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Variant1 { x: 1799, y: 1799 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Variant1 { x: 1799, y: 1799 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Variant1 { x: 1799, y: 1799 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10
+// lldb-command:continue
+
 #![feature(struct_variant)]
 
 enum Enum {
@@ -74,17 +127,17 @@ enum Enum {
 impl Enum {
 
     fn self_by_ref(&self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_by_val(self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_owned(~self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 }
index 0bac86b1e66aa346c3db94632e614fb2c3999561..489ea114e1f598766f708016e67baac5bd292e8c 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = -10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Struct<(u32, i32)> { x: (8888, -8888) }
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = -2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Struct<(u32, i32)> { x: (8888, -8888) }
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Struct<f64> { x: 1234.5 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Struct<f64> { x: 1234.5 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Struct<f64> { x: 1234.5 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10
+// lldb-command:continue
+
+
 struct Struct<T> {
     x: T
 }
@@ -71,17 +125,17 @@ struct Struct<T> {
 impl<T> Struct<T> {
 
     fn self_by_ref(&self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_by_val(self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_owned(~self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 }
index 3d7cc96ca171fa43175bc65ef814d4d96e23e8e8..f2db6e3af471e2d6bcb33a42724f5fd97b35c207 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = -10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Struct { x: 100 }
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = -2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Struct { x: 100 }
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10
+// lldb-command:continue
+
 struct Struct {
     x: int
 }
@@ -71,17 +124,17 @@ struct Struct {
 impl Struct {
 
     fn self_by_ref(&self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         self.x + arg1 + arg2
     }
 
     fn self_by_val(self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         self.x + arg1 + arg2
     }
 
     fn self_owned(~self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         self.x + arg1 + arg2
     }
 }
index a2b73629a6738d0bc89787521d3068122102980b..e38aace11b93bf334c9fab100296495e5a31b427 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = -10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Struct { x: 100 }
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = -2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Struct { x: 100 }
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10
+// lldb-command:continue
+
 struct Struct {
     x: int
 }
@@ -77,17 +130,17 @@ trait Trait {
 impl Trait for Struct {
 
     fn self_by_ref(&self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         self.x + arg1 + arg2
     }
 
     fn self_by_val(self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         self.x + arg1 + arg2
     }
 
     fn self_owned(~self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         self.x + arg1 + arg2
     }
 }
index fe7271716bb4fbdf0ba8192f12336e9b950ad4af..6f8a6182063b7ccab0fe531851c357e0e6d352bd 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = -10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = TupleStruct(100, -100.5)
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = -2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = TupleStruct(100, -100.5)
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = TupleStruct(200, -200.5)
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = TupleStruct(200, -200.5)
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = TupleStruct(200, -200.5)
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10
+// lldb-command:continue
+
 struct TupleStruct(int, f64);
 
 impl TupleStruct {
 
     fn self_by_ref(&self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_by_val(self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_owned(~self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 }
index 9e40f03c201626a8a791c6224089e8f77af0a28b..1d9427a3bfe68174e606bdce7b6b054a27ec6b9d 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print abc
 // gdb-check:$3 = 30303
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print abc
+// lldb-check:[...]$0 = 10101
+// lldb-command:continue
+
+// lldb-command:print abc
+// lldb-check:[...]$1 = 20202
+// lldb-command:continue
+
+// lldb-command:print abc
+// lldb-check:[...]$2 = 30303
+
 #![allow(unused_variable)]
 
 fn function_one() {
     let abc = 10101i;
-    zzz();
+    zzz(); // #break
 }
 
 fn function_two() {
     let abc = 20202i;
-    zzz();
+    zzz(); // #break
 }
 
 
 fn function_three() {
     let abc = 30303i;
-    zzz();
+    zzz(); // #break
 }
 
 
index ef1c69f9eb8cf50a2744ffcfc015a5f76c13afea..25d9dc02404338491f43a1fe1dc05c114bb31376 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print c
 // gdb-check:$3 = 30303
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print a
+// lldb-check:[...]$0 = 10101
+// lldb-command:continue
+
+// lldb-command:print b
+// lldb-check:[...]$1 = 20202
+// lldb-command:continue
+
+// lldb-command:print c
+// lldb-check:[...]$2 = 30303
+
 #![allow(unused_variable)]
 
 fn function_one() {
     let a = 10101i;
-    zzz();
+    zzz(); // #break
 }
 
 fn function_two() {
     let b = 20202i;
-    zzz();
+    zzz(); // #break
 }
 
 
 fn function_three() {
     let c = 30303i;
-    zzz();
+    zzz(); // #break
 }
 
 
index 8ee6d434016f0b946cdecc1e00a244d870deeee9..3462735f6d1093695c3e0e7eb333f1c967589eaa 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$12 = 20
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = false
+// lldb-command:print y
+// lldb-check:[...]$1 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 10
+// lldb-command:print y
+// lldb-check:[...]$3 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = 10.5
+// lldb-command:print y
+// lldb-check:[...]$5 = 20
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$6 = true
+// lldb-command:print y
+// lldb-check:[...]$7 = 2220
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$8 = 203203.5
+// lldb-command:print y
+// lldb-check:[...]$9 = 2220
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$10 = 10.5
+// lldb-command:print y
+// lldb-check:[...]$11 = 20
+// lldb-command:continue
+
 fn main() {
     let x = false;
     let y = true;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let x = 10i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let x = 10.5f64;
     let y = 20i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     {
         let x = true;
         let y = 2220i;
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 203203.5f64;
 
-        zzz();
+        zzz(); // #break
         sentinel();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 43d82e75c4dda0e516d160ce0f040702fe46390f..511786999abf34404c3157af71aef0ccc2225ed4 100644 (file)
@@ -8,6 +8,9 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// LLDB can't handle zero-sized values
+// ignore-lldb
+
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
index de6d6814308d8d6e0751a013909682690692ed9d..f9e2f61564bee93c00eea8a1f5f78c2b6a805ae7 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print full
 // gdb-check:$3 = {RUST$ENCODED$ENUM$1$Empty = {454545, 0x87654321, 9988}}
 
-// gdb-command:print empty->discr
+// gdb-command:print empty_gdb->discr
 // gdb-check:$4 = (int *) 0x0
 
 // gdb-command:print droid
 // gdb-check:$5 = {RUST$ENCODED$ENUM$2$Void = {id = 675675, range = 10000001, internals = 0x43218765}}
 
-// gdb-command:print void_droid->internals
+// gdb-command:print void_droid_gdb->internals
 // gdb-check:$6 = (int *) 0x0
 
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print some
+// lldb-check:[...]$0 = Some(&0x12345678)
+
+// lldb-command:print none
+// lldb-check:[...]$1 = None
+
+// lldb-command:print full
+// lldb-check:[...]$2 = Full(454545, &0x87654321, 9988)
+
+// lldb-command:print empty
+// lldb-check:[...]$3 = Empty
+
+// lldb-command:print droid
+// lldb-check:[...]$4 = Droid { id: 675675, range: 10000001, internals: &0x43218765 }
+
+// lldb-command:print void_droid
+// lldb-check:[...]$5 = Void
+
+
 #![feature(struct_variant)]
 
 // If a struct has exactly two variants, one of them is empty, and the other one
@@ -77,8 +104,8 @@ fn main() {
 
     let full = Full(454545, unsafe { std::mem::transmute(0x87654321u) }, 9988);
 
-    let int_val = 0i;
-    let empty: &MoreFieldsRepr = unsafe { std::mem::transmute(&Empty) };
+    let empty = Empty;
+    let empty_gdb: &MoreFieldsRepr = unsafe { std::mem::transmute(&Empty) };
 
     let droid = Droid {
         id: 675675,
@@ -86,9 +113,10 @@ fn main() {
         internals: unsafe { std::mem::transmute(0x43218765u) }
     };
 
-    let void_droid: &NamedFieldsRepr = unsafe { std::mem::transmute(&Void) };
+    let void_droid = Void;
+    let void_droid_gdb: &NamedFieldsRepr = unsafe { std::mem::transmute(&Void) };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 29087b18d5a96be140fb0507a896bcf5f3aabfca..215d961b71b0eb132be35f85acdaf3cf7e3b5466 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print deeplyNested
 // gdb-check:$8 = {a = {a = 1, b = {x = 2, y = 3, z = 4}, c = 5, d = {x = 6, y = 7, z = 8}}, b = {a = 9, b = {x = 10, y = 11, z = 12}, c = {x = 13, y = 14, z = 15}, d = 16}, c = {a = 17, b = {x = 18, y = 19, z = 20}, c = 21, d = {x = 22, y = 23, z = 24}}, d = {a = 25, b = {x = 26, y = 27, z = 28}, c = 29, d = {x = 30, y = 31, z = 32}}, e = {a = 33, b = {x = 34, y = 35, z = 36}, c = {x = 37, y = 38, z = 39}, d = 40}, f = {a = 41, b = {x = 42, y = 43, z = 44}, c = 45, d = {x = 46, y = 47, z = 48}}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print packed
+// lldb-check:[...]$0 = Packed { x: 123, y: 234, z: 345 }
+
+// lldb-command:print packedInPacked
+// lldb-check:[...]$1 = PackedInPacked { a: 1111, b: Packed { x: 2222, y: 3333, z: 4444 }, c: 5555, d: Packed { x: 6666, y: 7777, z: 8888 } }
+
+// lldb-command:print packedInUnpacked
+// lldb-check:[...]$2 = PackedInUnpacked { a: -1111, b: Packed { x: -2222, y: -3333, z: -4444 }, c: -5555, d: Packed { x: -6666, y: -7777, z: -8888 } }
+
+// lldb-command:print unpackedInPacked
+// lldb-check:[...]$3 = UnpackedInPacked { a: 987, b: Unpacked { x: 876, y: 765, z: 654 }, c: Unpacked { x: 543, y: 432, z: 321 }, d: 210 }
+
+// lldb-command:print packedInPackedWithDrop
+// lldb-check:[...]$4 = PackedInPackedWithDrop { a: 11, b: Packed { x: 22, y: 33, z: 44 }, c: 55, d: Packed { x: 66, y: 77, z: 88 } }
+
+// lldb-command:print packedInUnpackedWithDrop
+// lldb-check:[...]$5 = PackedInUnpackedWithDrop { a: -11, b: Packed { x: -22, y: -33, z: -44 }, c: -55, d: Packed { x: -66, y: -77, z: -88 } }
+
+// lldb-command:print unpackedInPackedWithDrop
+// lldb-check:[...]$6 = UnpackedInPackedWithDrop { a: 98, b: Unpacked { x: 87, y: 76, z: 65 }, c: Unpacked { x: 54, y: 43, z: 32 }, d: 21 }
+
+// lldb-command:print deeplyNested
+// lldb-check:[...]$7 = DeeplyNested { a: PackedInPacked { a: 1, b: Packed { x: 2, y: 3, z: 4 }, c: 5, d: Packed { x: 6, y: 7, z: 8 } }, b: UnpackedInPackedWithDrop { a: 9, b: Unpacked { x: 10, y: 11, z: 12 }, c: Unpacked { x: 13, y: 14, z: 15 }, d: 16 }, c: PackedInUnpacked { a: 17, b: Packed { x: 18, y: 19, z: 20 }, c: 21, d: Packed { x: 22, y: 23, z: 24 } }, d: PackedInUnpackedWithDrop { a: 25, b: Packed { x: 26, y: 27, z: 28 }, c: 29, d: Packed { x: 30, y: 31, z: 32 } }, e: UnpackedInPacked { a: 33, b: Unpacked { x: 34, y: 35, z: 36 }, c: Unpacked { x: 37, y: 38, z: 39 }, d: 40 }, f: PackedInPackedWithDrop { a: 41, b: Packed { x: 42, y: 43, z: 44 }, c: 45, d: Packed { x: 46, y: 47, z: 48 } } }
+
+
 #![allow(unused_variable)]
 
 #[packed]
@@ -216,7 +249,7 @@ fn main() {
         }
     };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index bc8156c73853c62f0087c1e81ede353d88729edb..8201afe3a016463229a8dafc705c19db8ed8921c 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print sizeof(packedInPacked)
 // gdb-check:$6 = 40
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print packed
+// lldb-check:[...]$0 = Packed { x: 123, y: 234, z: 345 }
+
+// lldb-command:print packedInPacked
+// lldb-check:[...]$1 = PackedInPacked { a: 1111, b: Packed { x: 2222, y: 3333, z: 4444 }, c: 5555, d: Packed { x: 6666, y: 7777, z: 8888 } }
+
+// lldb-command:print packedInUnpacked
+// lldb-check:[...]$2 = PackedInUnpacked { a: -1111, b: Packed { x: -2222, y: -3333, z: -4444 }, c: -5555, d: Packed { x: -6666, y: -7777, z: -8888 } }
+
+// lldb-command:print unpackedInPacked
+// lldb-check:[...]$3 = UnpackedInPacked { a: 987, b: Unpacked { x: 876, y: 765, z: 654, w: 543 }, c: Unpacked { x: 432, y: 321, z: 210, w: 109 }, d: -98 }
+
+// lldb-command:print sizeof(packed)
+// lldb-check:[...]$4 = 14
+
+// lldb-command:print sizeof(packedInPacked)
+// lldb-check:[...]$5 = 40
+
 #![allow(unused_variable)]
 
 #[packed]
@@ -101,7 +127,7 @@ fn main() {
         d: -98
     };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 68b6764a5a1501d1e54dd5da2a874f4316450d5a..4eb251c60841a8ebc8e8d998a46f75ff80bc9937 100644 (file)
@@ -10,6 +10,8 @@
 
 // ignore-android: FIXME(#10381)
 
+// ignore-lldb
+
 // compile-flags:-g
 // gdb-command:run
 
index ea0867903b5af3fbef0d4c970aca5e090997364c..931955ec31738b699efc17e70b6fe84e432db3f2 100644 (file)
@@ -10,6 +10,7 @@
 
 // ignore-tidy-linelength
 // ignore-android: FIXME(#10381)
+// ignore-lldb
 
 #![feature(managed_boxes)]
 
index 45cbcf094f4f5ea10b2148089c29c92369600644..ddca9bf0792f22199244aa9de271e99eb74e3bd9 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$15 = -10
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Struct { x: 100 }
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = -2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Struct { x: 100 }
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Struct { x: 200 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10
+// lldb-command:continue
+
+
 struct Struct {
     x: int
 }
 
 trait Trait {
     fn self_by_ref(&self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_by_val(self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 
     fn self_owned(~self, arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 }
index 8ab3fd44203aaf5a3bf75e61b0ba3b1264cbefda..57ffc4a2e19d68129b66805ff0c2f88a60fa9d70 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
@@ -20,8 +23,8 @@
 // gdb-check:$1 = {x = 987}
 // gdb-command:print arg1
 // gdb-check:$2 = -1
-// gdb-command:print/d arg2
-// gdb-check:$3 = -2
+// gdb-command:print arg2
+// gdb-check:$3 = 2
 // gdb-command:continue
 
 // STACK BY VAL
 // gdb-check:$15 = -10.5
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STACK BY REF
+// lldb-command:print *self
+// lldb-check:[...]$0 = Struct { x: 987 }
+// lldb-command:print arg1
+// lldb-check:[...]$1 = -1
+// lldb-command:print arg2
+// lldb-check:[...]$2 = 2
+// lldb-command:continue
+
+// STACK BY VAL
+// lldb-command:print self
+// lldb-check:[...]$3 = Struct { x: 987 }
+// lldb-command:print arg1
+// lldb-check:[...]$4 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$5 = -4
+// lldb-command:continue
+
+// OWNED BY REF
+// lldb-command:print *self
+// lldb-check:[...]$6 = Struct { x: 879 }
+// lldb-command:print arg1
+// lldb-check:[...]$7 = -5
+// lldb-command:print arg2
+// lldb-check:[...]$8 = -6
+// lldb-command:continue
+
+// OWNED BY VAL
+// lldb-command:print self
+// lldb-check:[...]$9 = Struct { x: 879 }
+// lldb-command:print arg1
+// lldb-check:[...]$10 = -7
+// lldb-command:print arg2
+// lldb-check:[...]$11 = -8
+// lldb-command:continue
+
+// OWNED MOVED
+// lldb-command:print *self
+// lldb-check:[...]$12 = Struct { x: 879 }
+// lldb-command:print arg1
+// lldb-check:[...]$13 = -9
+// lldb-command:print arg2
+// lldb-check:[...]$14 = -10.5
+// lldb-command:continue
+
+
 struct Struct {
     x: int
 }
@@ -71,17 +125,17 @@ struct Struct {
 trait Trait {
 
     fn self_by_ref<T>(&self, arg1: int, arg2: T) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 
     fn self_by_val<T>(self, arg1: int, arg2: T) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 
     fn self_owned<T>(~self, arg1: int, arg2: T) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 }
@@ -90,7 +144,7 @@ impl Trait for Struct {}
 
 fn main() {
     let stack = Struct { x: 987 };
-    let _ = stack.self_by_ref(-1, -2_i8);
+    let _ = stack.self_by_ref(-1, 2_u16);
     let _ = stack.self_by_val(-3, -4_i16);
 
     let owned = box Struct { x: 879 };
index c180d6b5bcfe7c5eadfb7af99544eb5d6bd80534..7a9c7c3b372f4f549a24caf2400cdf74a7abcdba 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$6 = 20
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = false
+// lldb-command:print y
+// lldb-check:[...]$1 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 10
+// lldb-command:print y
+// lldb-check:[...]$3 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = 10.5
+// lldb-command:print y
+// lldb-check:[...]$5 = 20
+// lldb-command:continue
+
 fn a_function(x: bool, y: bool) {
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let x = 10i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let x = 10.5f64;
     let y = 20i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index 88ef3c4879e90d41eafe019100e0987b0cd1945a..a43bb5e4017309bb28c01d27306320d48e90e851 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$6 = 20
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = false
+// lldb-command:print y
+// lldb-check:[...]$1 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 10
+// lldb-command:print y
+// lldb-check:[...]$3 = true
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = 10.5
+// lldb-command:print y
+// lldb-check:[...]$5 = 20
+// lldb-command:continue
+
 fn main() {
     let x = false;
     let y = true;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let x = 10i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     let x = 10.5f64;
     let y = 20i;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index b84405ee7270e76271bd289cb26dfc27cedd923c..eee1d0e70ca5fd693c488f6d45e4321c0e2fd38c 100644 (file)
@@ -8,6 +8,9 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// Need a fix for LLDB first...
+// ignore-lldb
+
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
index 107b64131e053d577b0e5a21ab81ae0414c7ea08..a012ee265d4a90661e79ab97e64a4befa7da94be 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-command:continue
 
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print x
+// lldb-check:[...]$0 = false
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$1 = false
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$2 = 10
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$3 = 10
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$4 = 10.5
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$5 = 10
+// lldb-command:continue
+
+// lldb-command:print x
+// lldb-check:[...]$6 = false
+// lldb-command:continue
+
 fn main() {
     let x = false;
 
-    zzz();
+    zzz(); // #break
     sentinel();
 
     {
-        zzz();
+        zzz(); // #break
         sentinel();
 
         let x = 10i;
 
-        zzz();
+        zzz(); // #break
         sentinel();
 
         {
-            zzz();
+            zzz(); // #break
             sentinel();
 
             let x = 10.5f64;
 
-            zzz();
+            zzz(); // #break
             sentinel();
         }
 
-        zzz();
+        zzz(); // #break
         sentinel();
     }
 
-    zzz();
+    zzz(); // #break
     sentinel();
 }
 
index c1f0e2c1f9ea78925f22d2d7a92e8534c6c8bb16..5076673c3a512c897fae9608400927eb858253e7 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 
 // gdb-check:$19 = {a = 10019, b = -10020, x = -10016, y = -10017.5, z = 10018}
 
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print no_padding16
+// lldb-check:[...]$0 = NoPadding16 { x: 10000, y: -10001 }
+
+// lldb-command:print no_padding32
+// lldb-check:[...]$1 = NoPadding32 { x: -10002, y: -10003.5, z: 10004 }
+
+// lldb-command:print no_padding64
+// lldb-check:[...]$2 = NoPadding64 { x: -10005.5, y: 10006, z: 10007 }
+
+// lldb-command:print no_padding163264
+// lldb-check:[...]$3 = NoPadding163264 { a: -10008, b: 10009, c: 10010, d: 10011 }
+
+// lldb-command:print internal_padding
+// lldb-check:[...]$4 = InternalPadding { x: 10012, y: -10013 }
+
+// lldb-command:print padding_at_end
+// lldb-check:[...]$5 = PaddingAtEnd { x: -10014, y: 10015 }
+
 #![feature(struct_inherit)];
 #![allow(unused_variable)];
 #![allow(dead_code)];
@@ -188,7 +213,7 @@ fn main() {
         PADDING_AT_END.y = 28;
     }
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 9486ab2474eff07d81611bd69d097b564ee69f38..29d739d7f183abce044f55edc83ef0ea726fb676 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 
 // gdb-command:print 'simple-tuple::PADDING_AT_END'
 // gdb-check:$21 = {116, 117}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print/d noPadding8
+// lldb-check:[...]$0 = (-100, 100)
+// lldb-command:print noPadding16
+// lldb-check:[...]$1 = (0, 1, 2)
+// lldb-command:print noPadding32
+// lldb-check:[...]$2 = (3, 4.5, 5)
+// lldb-command:print noPadding64
+// lldb-check:[...]$3 = (6, 7.5, 8)
+
+// lldb-command:print internalPadding1
+// lldb-check:[...]$4 = (9, 10)
+// lldb-command:print internalPadding2
+// lldb-check:[...]$5 = (11, 12, 13, 14)
+
+// lldb-command:print paddingAtEnd
+// lldb-check:[...]$6 = (15, 16)
+
 #![allow(unused_variable)]
 #![allow(dead_code)]
 
@@ -107,7 +132,7 @@ fn main() {
         PADDING_AT_END = (116, 117);
     }
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index d7d962c07d6ded530ebc93efdbffab04b27338b0..e5f9651bb8bcf1b294b60837b42358cc7b3ac5a1 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-check:$5 = 5
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// STRUCT
+// lldb-command:print arg1
+// lldb-check:[...]$0 = 1
+// lldb-command:print arg2
+// lldb-check:[...]$1 = 2
+// lldb-command:continue
+
+// ENUM
+// lldb-command:print arg1
+// lldb-check:[...]$2 = -3
+// lldb-command:print arg2
+// lldb-check:[...]$3 = 4.5
+// lldb-command:print arg3
+// lldb-check:[...]$4 = 5
+// lldb-command:continue
+
 #![feature(struct_variant)]
 
 struct Struct {
@@ -41,7 +65,7 @@ struct Struct {
 impl Struct {
 
     fn static_method(arg1: int, arg2: int) -> int {
-        zzz();
+        zzz(); // #break
         arg1 + arg2
     }
 }
@@ -55,7 +79,7 @@ enum Enum {
 impl Enum {
 
     fn static_method(arg1: int, arg2: f64, arg3: uint) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 }
index 0cba56ad320ec834ce77cda38252487f0823a26c..d01119bce05338ce3c618c8d8feddd3f8259b671 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print union on
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print univariant
 // gdb-check:$3 = {{{x = 123, y = 456, z = 789}}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print case1
+// lldb-check:[...]$0 = Case1(0, Struct { x: 2088533116, y: 2088533116, z: 31868 })
+// lldb-command:print case2
+// lldb-check:[...]$1 = Case2(0, 1229782938247303441, 4369)
+
+// lldb-command:print univariant
+// lldb-check:[...]$2 = TheOnlyCase(Struct { x: 123, y: 456, z: 789 })
+
 #![allow(unused_variable)]
 
 struct Struct {
@@ -66,7 +82,7 @@ fn main() {
 
     let univariant = TheOnlyCase(Struct { x: 123, y: 456, z: 789 });
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index e4c3f471880dfd78122731308aec5fbf2a5951df..3822b80e8650feac36b189a33cc7019f9b1a10ca 100644 (file)
@@ -8,9 +8,13 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// ignore-tidy-linelength
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print padding_at_end_parent
 // gdb-check:$3 = {x = {x = 10, y = 11}, y = {x = 12, y = 13}, z = {x = 14, y = 15}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print three_simple_structs
+// lldb-check:[...]$0 = ThreeSimpleStructs { x: Simple { x: 1 }, y: Simple { x: 2 }, z: Simple { x: 3 } }
+
+// lldb-command:print internal_padding_parent
+// lldb-check:[...]$1 = InternalPaddingParent { x: InternalPadding { x: 4, y: 5 }, y: InternalPadding { x: 6, y: 7 }, z: InternalPadding { x: 8, y: 9 } }
+
+// lldb-command:print padding_at_end_parent
+// lldb-check:[...]$2 = PaddingAtEndParent { x: PaddingAtEnd { x: 10, y: 11 }, y: PaddingAtEnd { x: 12, y: 13 }, z: PaddingAtEnd { x: 14, y: 15 } }
+
+// lldb-command:print mixed
+// lldb-check:[...]$3 = Mixed { x: PaddingAtEnd { x: 16, y: 17 }, y: InternalPadding { x: 18, y: 19 }, z: Simple { x: 20 }, w: 21 }
+
+// lldb-command:print bag
+// lldb-check:[...]$4 = Bag { x: Simple { x: 22 } }
+
+// lldb-command:print bag_in_bag
+// lldb-check:[...]$5 = BagInBag { x: Bag { x: Simple { x: 23 } } }
+
+// lldb-command:print tjo
+// lldb-check:[...]$6 = ThatsJustOverkill { x: BagInBag { x: Bag { x: Simple { x: 24 } } } }
+
+// lldb-command:print tree
+// lldb-check:[...]$7 = Tree { x: Simple { x: 25 }, y: InternalPaddingParent { x: InternalPadding { x: 26, y: 27 }, y: InternalPadding { x: 28, y: 29 }, z: InternalPadding { x: 30, y: 31 } }, z: BagInBag { x: Bag { x: Simple { x: 32 } } } }
+
 #![allow(unused_variable)]
 
 struct Simple {
@@ -140,7 +173,7 @@ fn main() {
         }
     };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 70d4d709d23c81547ad410057f09d40027a8866e..c3a5abf2d389a67e25c5b431938c885d2a7e5fe0 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print union on
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print univariant
 // gdb-check:$4 = {{a = -1}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print case1
+// lldb-check:[...]$0 = Case1 { a: 0, b: 31868, c: 31868, d: 31868, e: 31868 }
+
+// lldb-command:print case2
+// lldb-check:[...]$1 = Case2 { a: 0, b: 286331153, c: 286331153 }
+
+// lldb-command:print case3
+// lldb-check:[...]$2 = Case3 { a: 0, b: 6438275382588823897 }
+
+// lldb-command:print univariant
+// lldb-check:[...]$3 = TheOnlyCase { a: -1 }
+
 #![allow(unused_variable)]
 #![feature(struct_variant)]
 
@@ -71,7 +91,7 @@ fn main() {
 
     let univariant = TheOnlyCase { a: -1 };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 16fbfc49d08ed625b8abe4be6fcb1b96683a4087..525fcd45cfb06cbeed3d2c53be09f0aa20651c74 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print nested
 // gdb-check:$4 = {a = {a = {x = 7890, y = 9870}}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+// lldb-command:print simple
+// lldb-check:[...]$0 = WithDestructor { x: 10, y: 20 }
+
+// lldb-command:print noDestructor
+// lldb-check:[...]$1 = NoDestructorGuarded { a: NoDestructor { x: 10, y: 20 }, guard: -1 }
+
+// lldb-command:print withDestructor
+// lldb-check:[...]$2 = WithDestructorGuarded { a: WithDestructor { x: 10, y: 20 }, guard: -1 }
+
+// lldb-command:print nested
+// lldb-check:[...]$3 = NestedOuter { a: NestedInner { a: WithDestructor { x: 7890, y: 9870 } } }
+
 #![allow(unused_variable)]
 
 struct NoDestructor {
@@ -121,7 +140,7 @@ fn main() {
     //                            <-------NestedOuter-------->
     let nested = NestedOuter { a: NestedInner { a: WithDestructor { x: 7890, y: 9870 } } };
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 91e2445c4aa9d12d6d7ed9cd2aef088c97c8f498..ba055272a3fa78f94978f2d0818bb777616cdab8 100644 (file)
@@ -1 +1 @@
-some text to include in another file as string 1
+some text to include in another file as string 1
\ No newline at end of file
index be6022776c52160438438cc980ce31b0792d814d..a59d2057eb46b013c86bcda3feec70488790abf1 100644 (file)
@@ -1 +1 @@
-some text to include in another file as string 2
+some text to include in another file as string 2.
\ No newline at end of file
index 0cff667b47ca029a82df1676ad167d8cc7b0b197..6163f7dd48cd496a445ee85a703fb328eb6d9d79 100644 (file)
@@ -1 +1 @@
-some text to include in another file as string 3
+some text to include in another file as string 3..
\ No newline at end of file
index e91cd2f02d4888b5e800de6bb2d1a5f894010d5c..20747681b6ffaf39fb927bb66d536dbc423a6a4c 100644 (file)
@@ -11,6 +11,9 @@
 // except according to those terms.
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 
 // gdb-command:continue
 
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print no_padding1
+// lldb-check:[...]$0 = { x = (0, 1) y = 2 z = (3, 4, 5) }
+// lldb-command:print no_padding2
+// lldb-check:[...]$1 = { x = (6, 7) y = { = (8, 9) = 10 } }
+
+// lldb-command:print tuple_internal_padding
+// lldb-check:[...]$2 = { x = (11, 12) y = (13, 14) }
+// lldb-command:print struct_internal_padding
+// lldb-check:[...]$3 = { x = (15, 16) y = (17, 18) }
+// lldb-command:print both_internally_padded
+// lldb-check:[...]$4 = { x = (19, 20, 21) y = (22, 23) }
+
+// lldb-command:print single_tuple
+// lldb-check:[...]$5 = { x = (24, 25, 26) }
+
+// lldb-command:print tuple_padded_at_end
+// lldb-check:[...]$6 = { x = (27, 28) y = (29, 30) }
+// lldb-command:print struct_padded_at_end
+// lldb-check:[...]$7 = { x = (31, 32) y = (33, 34) }
+// lldb-command:print both_padded_at_end
+// lldb-check:[...]$8 = { x = (35, 36, 37) y = (38, 39) }
+
+// lldb-command:print mixed_padding
+// lldb-check:[...]$9 = { x = { = (40, 41, 42) = (43, 44) } y = (45, 46, 47, 48) }
+
 struct Struct {
     x: int
 }
 
 trait Trait {
     fn generic_static_default_method<T>(arg1: int, arg2: T) -> int {
-        zzz();
+        zzz(); // #break
         arg1
     }
 }
index e58ed4cea29a78c5999154c22326d3ab24f02e70..ca407aef1a45e8bd4cd67cfe040da74124c29037 100644 (file)
@@ -10,6 +10,8 @@
 
 // ignore-android: FIXME(#10381)
 
+// ignore-lldb
+
 // compile-flags:-g
 // gdb-command:run
 
index 3cc8b4e6486d6e7553c1801e06fa5483f335b1d5..4c4ad51c70bb026e5ff9b66082ff540ce9eccb97 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print padding_at_end2
 // gdb-check:$7 = {{21, 22}, 23}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print no_padding1
+// lldb-check:[...]$0 = ((0, 1), 2, 3)
+// lldb-command:print no_padding2
+// lldb-check:[...]$1 = (4, (5, 6), 7)
+// lldb-command:print no_padding3
+// lldb-check:[...]$2 = (8, 9, (10, 11))
+
+// lldb-command:print internal_padding1
+// lldb-check:[...]$3 = (12, (13, 14))
+// lldb-command:print internal_padding2
+// lldb-check:[...]$4 = (15, (16, 17))
+
+// lldb-command:print padding_at_end1
+// lldb-check:[...]$5 = (18, (19, 20))
+// lldb-command:print padding_at_end2
+// lldb-check:[...]$6 = ((21, 22), 23)
+
 #![allow(unused_variable)]
 
 fn main() {
@@ -46,7 +71,7 @@ fn main() {
     let padding_at_end1: (i32, (i32, i16)) = (18, (19, 20));
     let padding_at_end2: ((i32, i16), i32) = ((21, 22), 23);
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index cea063820b86754f7b11b07ee8a08919fb27d891..afcacd46e6653a258d2b9e59328293378957a89e 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-check:$6 = {-10014, 10015}
 
 
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print no_padding16
+// lldb-check:[...]$0 = NoPadding16(10000, -10001)
+
+// lldb-command:print no_padding32
+// lldb-check:[...]$1 = NoPadding32(-10002, -10003.5, 10004)
+
+// lldb-command:print no_padding64
+// lldb-check:[...]$2 = NoPadding64(-10005.5, 10006, 10007)
+
+// lldb-command:print no_padding163264
+// lldb-check:[...]$3 = NoPadding163264(-10008, 10009, 10010, 10011)
+
+// lldb-command:print internal_padding
+// lldb-check:[...]$4 = InternalPadding(10012, -10013)
+
+// lldb-command:print padding_at_end
+// lldb-check:[...]$5 = PaddingAtEnd(-10014, 10015)
+
 // This test case mainly makes sure that no field names are generated for tuple structs (as opposed
 // to all fields having the name "<unnamed_field>"). Otherwise they are handled the same a normal
 // structs.
@@ -55,7 +80,7 @@ fn main() {
     let internal_padding = InternalPadding(10012, -10013);
     let padding_at_end = PaddingAtEnd(-10014, 10015);
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 81c72d16886439bc468288a3087ff198286a8ffe..7cd0a8f6164e8102816c3951a09dd3feb99a386f 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print union on
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print univariant
 // gdb-check:$4 = {{-1}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print case1
+// lldb-check:[...]$0 = Case1(0, 31868, 31868, 31868, 31868)
+
+// lldb-command:print case2
+// lldb-check:[...]$1 = Case2(0, 286331153, 286331153)
+
+// lldb-command:print case3
+// lldb-check:[...]$2 = Case3(0, 6438275382588823897)
+
+// lldb-command:print univariant
+// lldb-check:[...]$3 = TheOnlyCase(-1)
+
 #![allow(unused_variable)]
 
 // The first element is to ensure proper alignment, irrespective of the machines word size. Since
@@ -70,7 +90,7 @@ fn main() {
 
     let univariant = TheOnlyCase(-1);
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 3949a315adca2b79783cca5175e6f8ec672f06f5..4c945e62abcd8cb057b1848c57d968d446c484c8 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *univariant
 // gdb-check:$3 = {{123234}}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print *the_a
+// lldb-check:[...]$0 = TheA { x: 0, y: 8970181431921507452 }
+
+// lldb-command:print *the_b
+// lldb-check:[...]$1 = TheB(0, 286331153, 286331153)
+
+// lldb-command:print *univariant
+// lldb-check:[...]$2 = TheOnlyCase(123234)
+
 #![allow(unused_variable)]
 #![feature(struct_variant)]
 
@@ -60,7 +77,7 @@ fn main() {
 
     let univariant = box TheOnlyCase(123234);
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 3328b11228441ee31a5e66ea7218bb850d6e338c..b538fcd7d76b83a858c03378485ada6e62db6c67 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-check:$14 = 8
 // gdb-command:continue
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print variable
+// lldb-check:[...]$0 = 1
+// lldb-command:print constant
+// lldb-check:[...]$1 = 2
+// lldb-command:print a_struct
+// lldb-check:[...]$2 = Struct { a: -3, b: 4.5, c: 5 }
+// lldb-command:print *struct_ref
+// lldb-check:[...]$3 = Struct { a: -3, b: 4.5, c: 5 }
+// lldb-command:print *owned
+// lldb-check:[...]$4 = 6
+// lldb-command:print managed->val
+// lldb-check:[...]$5 = 7
+// lldb-command:print closure_local
+// lldb-check:[...]$6 = 8
+// lldb-command:continue
+
+// lldb-command:print variable
+// lldb-check:[...]$7 = 1
+// lldb-command:print constant
+// lldb-check:[...]$8 = 2
+// lldb-command:print a_struct
+// lldb-check:[...]$9 = Struct { a: -3, b: 4.5, c: 5 }
+// lldb-command:print *struct_ref
+// lldb-check:[...]$10 = Struct { a: -3, b: 4.5, c: 5 }
+// lldb-command:print *owned
+// lldb-check:[...]$11 = 6
+// lldb-command:print managed->val
+// lldb-check:[...]$12 = 7
+// lldb-command:print closure_local
+// lldb-check:[...]$13 = 8
+// lldb-command:continue
+
 #![feature(managed_boxes)]
 #![allow(unused_variable)]
 
@@ -77,11 +117,11 @@ fn main() {
         let closure_local = 8;
 
         let nested_closure = || {
-            zzz();
+            zzz(); // #break
             variable = constant + a_struct.a + struct_ref.a + *owned + *managed + closure_local;
         };
 
-        zzz();
+        zzz(); // #break
 
         nested_closure();
     };
index 03525a3a034dc1b1f0c397a31538f310f3c70232..cd100415cbec6bc753983261ae900b6ae3ce3e6d 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print *owned
 // gdb-check:$3 = 5
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print constant
+// lldb-check:[...]$0 = 1
+// lldb-command:print a_struct
+// lldb-check:[...]$1 = Struct { a: -2, b: 3.5, c: 4 }
+// lldb-command:print *owned
+// lldb-check:[...]$2 = 5
+
 #![allow(unused_variable)]
 
 struct Struct {
@@ -42,7 +57,7 @@ fn main() {
     let owned = box 5;
 
     let closure: proc() = proc() {
-        zzz();
+        zzz(); // #break
         do_something(&constant, &a_struct.a, owned);
     };
 
index 453ac35463178429672c193d982f4c5febc73b7a..3fe17dc83e76591839d55b00b18b49ba99f7a3d7 100644 (file)
@@ -11,6 +11,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:finish
 // gdb-command:print managed->val
 // gdb-check:$6 = 7
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print variable
+// lldb-check:[...]$0 = 1
+// lldb-command:print constant
+// lldb-check:[...]$1 = 2
+// lldb-command:print a_struct
+// lldb-check:[...]$2 = Struct { a: -3, b: 4.5, c: 5 }
+// lldb-command:print *struct_ref
+// lldb-check:[...]$3 = Struct { a: -3, b: 4.5, c: 5 }
+// lldb-command:print *owned
+// lldb-check:[...]$4 = 6
+// lldb-command:print managed->val
+// lldb-check:[...]$5 = 7
+
 #![feature(managed_boxes)]
 #![allow(unused_variable)]
 
@@ -54,7 +75,7 @@ fn main() {
     let managed = box(GC) 7;
 
     let closure = || {
-        zzz();
+        zzz(); // #break
         variable = constant + a_struct.a + struct_ref.a + *owned + *managed;
     };
 
index 783b198395339b2fc916defa8abf50f538ad8eb7..00398fd5c8234fbb2d059c3eee3361643b554454 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print *((int64_t[2]*)('vec-slices::MUT_VECT_SLICE'.data_ptr))
 // gdb-check:$15 = {64, 65}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+
+// lldb-command:print empty
+// lldb-check:[...]$0 = &[]
+
+// lldb-command:print singleton
+// lldb-check:[...]$1 = &[1]
+
+// lldb-command:print multiple
+// lldb-check:[...]$2 = &[2, 3, 4, 5]
+
+// lldb-command:print slice_of_slice
+// lldb-check:[...]$3 = &[3, 4]
+
+// lldb-command:print padded_tuple
+// lldb-check:[...]$4 = &[(6, 7), (8, 9)]
+
+// lldb-command:print padded_struct
+// lldb-check:[...]$5 = &[AStruct { x: 10, y: 11, z: 12 }, AStruct { x: 13, y: 14, z: 15 }]
+
 #![allow(unused_variable)]
 
 struct AStruct {
@@ -81,7 +107,7 @@ fn main() {
         MUT_VECT_SLICE = VECT_SLICE;
     }
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}
index 155865f415b6398aab09a1f6557108892a66961c..7372a6e7ca019bc6e27bc424e7850f4dac134c9a 100644 (file)
@@ -12,6 +12,9 @@
 // ignore-android: FIXME(#10381)
 
 // compile-flags:-g
+
+// === GDB TESTS ===================================================================================
+
 // gdb-command:set print pretty off
 // gdb-command:rbreak zzz
 // gdb-command:run
 // gdb-command:print vec::VECT
 // gdb-check:$2 = {4, 5, 6}
 
+
+// === LLDB TESTS ==================================================================================
+
+// lldb-command:run
+// lldb-command:print a
+// lldb-check:[...]$0 = [1, 2, 3]
+
 #![allow(unused_variable)]
 
 static mut VECT: [i32, ..3] = [1, 2, 3];
@@ -34,7 +44,7 @@ fn main() {
         VECT[2] = 6;
     }
 
-    zzz();
+    zzz(); // #break
 }
 
 fn zzz() {()}