diff options
author | Araq <rumpf_a@web.de> | 2013-06-06 14:16:16 -0700 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2013-06-06 14:16:16 -0700 |
commit | ce378d89849485369f556e5d46688e94671d77dc (patch) | |
tree | f36d96e3176fa167a0b0b169649e4905d3d340d6 /lib | |
parent | 9604df84316af83fe80a77ad1aeb2eacdd0466cb (diff) | |
parent | 7ea77d93e370040b4971c9f209e4b465c49721a5 (diff) | |
download | Nim-ce378d89849485369f556e5d46688e94671d77dc.tar.gz |
Merge pull request #464 from fowlmouth/patch-8
made macros.dumptree and dumplisp immediate, deprecated the *_imm versions
Diffstat (limited to 'lib')
-rw-r--r-- | lib/core/macros.nim | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/core/macros.nim b/lib/core/macros.nim index bbf970102..720b15189 100644 --- a/lib/core/macros.nim +++ b/lib/core/macros.nim @@ -390,7 +390,7 @@ proc lispRepr*(n: PNimrodNode): string {.compileTime.} = add(result, ")") -macro dumpTree*(s: stmt): stmt = echo s.treeRepr +macro dumpTree*(s: stmt): stmt {.immediate.} = echo s.treeRepr ## Accepts a block of nimrod code and prints the parsed abstract syntax ## tree using the `toTree` function. Printing is done *at compile time*. ## @@ -398,16 +398,16 @@ macro dumpTree*(s: stmt): stmt = echo s.treeRepr ## tree and to discover what kind of nodes must be created to represent ## a certain expression/statement. -macro dumpLisp*(s: stmt): stmt = echo s.lispRepr +macro dumpLisp*(s: stmt): stmt {.immediate.} = echo s.lispRepr ## Accepts a block of nimrod code and prints the parsed abstract syntax ## tree using the `toLisp` function. Printing is done *at compile time*. ## ## See `dumpTree`. -macro dumpTreeImm*(s: stmt): stmt {.immediate.} = echo s.treeRepr +macro dumpTreeImm*(s: stmt): stmt {.immediate, deprecated.} = echo s.treeRepr ## The ``immediate`` version of `dumpTree`. -macro dumpLispImm*(s: stmt): stmt {.immediate.} = echo s.lispRepr +macro dumpLispImm*(s: stmt): stmt {.immediate, deprecated.} = echo s.lispRepr ## The ``immediate`` version of `dumpLisp`. |