summary refs log tree commit diff stats
path: root/tests/reject/tno_int_in_bool_context.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2011-03-25 00:47:03 +0100
committerAraq <rumpf_a@web.de>2011-03-25 00:47:03 +0100
commit032599c156260a0892522b6ce858b1cdff08df84 (patch)
tree582c86f5e7a23595e1253af47133be3c4764da1f /tests/reject/tno_int_in_bool_context.nim
parent220dd54acfd5527c7c569811013b178fc462898e (diff)
downloadNim-032599c156260a0892522b6ce858b1cdff08df84.tar.gz
bugfix: type converter that converts to bool in 'if' context
Diffstat (limited to 'tests/reject/tno_int_in_bool_context.nim')
-rw-r--r--tests/reject/tno_int_in_bool_context.nim8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/reject/tno_int_in_bool_context.nim b/tests/reject/tno_int_in_bool_context.nim
new file mode 100644
index 000000000..a98a14826
--- /dev/null
+++ b/tests/reject/tno_int_in_bool_context.nim
@@ -0,0 +1,8 @@
+discard """
+  line: 6
+  errormsg: "Error: type mismatch: got (int) but expected 'bool'"
+"""
+
+if 1: 
+  echo "wtf?"
+