about summary refs log tree commit diff
path: root/src/test/compile-fail/and-init.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/compile-fail/and-init.rs')
-rw-r--r--src/test/compile-fail/and-init.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/compile-fail/and-init.rs b/src/test/compile-fail/and-init.rs
new file mode 100644
index 00000000000..7fa9c543557
--- /dev/null
+++ b/src/test/compile-fail/and-init.rs
@@ -0,0 +1,9 @@
+// xfail-stage0
+// error-pattern: Unsatisfied precondition constraint (for example, init(i
+
+fn main() {
+  let int i;
+
+  log (false && {i = 5; true});
+  log i;
+}
\ No newline at end of file