summaryrefslogtreecommitdiffstats
path: root/src/test/ui/panic-runtime/unwind-rec2.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/panic-runtime/unwind-rec2.rs')
-rw-r--r--src/test/ui/panic-runtime/unwind-rec2.rs23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/test/ui/panic-runtime/unwind-rec2.rs b/src/test/ui/panic-runtime/unwind-rec2.rs
new file mode 100644
index 000000000..a130f9e87
--- /dev/null
+++ b/src/test/ui/panic-runtime/unwind-rec2.rs
@@ -0,0 +1,23 @@
+// run-fail
+// error-pattern:explicit panic
+// ignore-emscripten no processes
+
+fn build1() -> Vec<isize> {
+ vec![0, 0, 0, 0, 0, 0, 0]
+}
+
+fn build2() -> Vec<isize> {
+ panic!();
+}
+
+struct Blk {
+ node: Vec<isize>,
+ span: Vec<isize>,
+}
+
+fn main() {
+ let _blk = Blk {
+ node: build1(),
+ span: build2(),
+ };
+}