diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2018-06-10 18:05:43 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-06-10 18:05:43 +0200 |
commit | 8db27d30e6153fc943ef54e837ed9a3df7d56004 (patch) | |
tree | e30a16dd083b7fe5dfc52adb2f3ab1bbe46a2776 /compiler/pragmas.nim | |
parent | 2662d713f71da542e662860a3cadb5c57e4f7592 (diff) | |
download | Nim-8db27d30e6153fc943ef54e837ed9a3df7d56004.tar.gz |
record cppdefine for incremental compilation
Diffstat (limited to 'compiler/pragmas.nim')
-rw-r--r-- | compiler/pragmas.nim | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/pragmas.nim b/compiler/pragmas.nim index a51d250a2..bfb06e00a 100644 --- a/compiler/pragmas.nim +++ b/compiler/pragmas.nim @@ -748,10 +748,12 @@ proc singlePragma(c: PContext, sym: PSym, n: PNode, i: var int, of wImportc: let name = getOptionalStr(c, it, "$1") cppDefine(c.config, name) + recordPragma(c, it, "cppdefine", name) makeExternImport(c, sym, name, it.info) of wImportCompilerProc: let name = getOptionalStr(c, it, "$1") cppDefine(c.config, name) + recordPragma(c, it, "cppdefine", name) processImportCompilerProc(c, sym, name, it.info) of wExtern: setExternName(c, sym, expectStrLit(c, it), it.info) of wImmediate: @@ -844,6 +846,7 @@ proc singlePragma(c: PContext, sym: PSym, n: PNode, i: var int, of wCompilerProc, wCore: noVal(c, it) # compilerproc may not get a string! cppDefine(c.graph.config, sym.name.s) + recordPragma(c, it, "cppdefine", sym.name.s) if sfFromGeneric notin sym.flags: markCompilerProc(c, sym) of wProcVar: noVal(c, it) |