summary refs log tree commit diff stats
path: root/compiler/parser.nim
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2016-01-15 11:34:52 +0100
committerAndreas Rumpf <rumpf_a@web.de>2016-01-15 11:34:52 +0100
commit46f1f41cc94fae52d26bf49e2b6eb74987857d9a (patch)
tree2a5757e2824f9133e413f464d9161fad6b9425a1 /compiler/parser.nim
parent9429e0f06458ab806deb88548622e93a9abb48fa (diff)
downloadNim-46f1f41cc94fae52d26bf49e2b6eb74987857d9a.tar.gz
finally removes 'echo ' gotcha
Diffstat (limited to 'compiler/parser.nim')
-rw-r--r--compiler/parser.nim12
1 files changed, 7 insertions, 5 deletions
diff --git a/compiler/parser.nim b/compiler/parser.nim
index 11dd6788a..eb0ef071d 100644
--- a/compiler/parser.nim
+++ b/compiler/parser.nim
@@ -250,12 +250,14 @@ proc isUnary(p: TParser): bool =
   if p.tok.tokType in {tkOpr, tkDotDot} and
      p.tok.strongSpaceB == 0 and
      p.tok.strongSpaceA > 0:
-    # XXX change this after 0.10.4 is out
-    if p.strongSpaces:
       result = true
-    else:
-      parMessage(p, warnDeprecated,
-        "will be parsed as unary operator; inconsistent spacing")
+      # versions prior to 0.13.0 used to do this:
+      when false:
+        if p.strongSpaces:
+          result = true
+        else:
+          parMessage(p, warnDeprecated,
+            "will be parsed as unary operator; inconsistent spacing")
 
 proc checkBinary(p: TParser) {.inline.} =
   ## Check if the current parser token is a binary operator.