summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorshirleyquirk <31934565+shirleyquirk@users.noreply.github.com>2020-10-01 17:07:55 +0100
committerGitHub <noreply@github.com>2020-10-01 18:07:55 +0200
commit84d9b1227d036e2286cbceace0d8dd27c515c62b (patch)
treeddeeaa4aac5d4b40771ac31afe338bb8d90352e6
parent26d656e73e2354bc6f177073b948a7791e8f7427 (diff)
downloadNim-84d9b1227d036e2286cbceace0d8dd27c515c62b.tar.gz
fixes #15430, pop pragma takes invalid input (#15449)
* fix #15430, pop pragma

{.pop, experimental.} should be allowed, but not {.pop experimental.}
-rw-r--r--compiler/pragmas.nim4
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/pragmas.nim b/compiler/pragmas.nim
index 3b7ae175d..67e574d52 100644
--- a/compiler/pragmas.nim
+++ b/compiler/pragmas.nim
@@ -1037,7 +1037,9 @@ proc singlePragma(c: PContext, sym: PSym, n: PNode, i: var int,
       of wPush:
         processPush(c, n, i + 1)
         result = true
-      of wPop: processPop(c, it)
+      of wPop:
+        processPop(c, it)
+        result = true
       of wPragma:
         if not sym.isNil and sym.kind == skTemplate:
           sym.flags.incl sfCustomPragma