* fix #12558
* Update compiler/pragmas.nim
This commit is contained in:
flywind 2020-11-09 18:46:25 +08:00 • committed by GitHub
commit 673c5990c6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 1 deletions

View file

@ -896,7 +896,11 @@ proc singlePragma(c: PContext, sym: PSym, n: PNode, i: var int,
of wMagic: processMagic(c, it, sym)
of wCompileTime:
noVal(c, it)
incl(sym.flags, sfCompileTime)
if comesFromPush:
if sym.kind in {skProc, skFunc}:
incl(sym.flags, sfCompileTime)
else:
incl(sym.flags, sfCompileTime)
#incl(sym.loc.flags, lfNoDecl)
of wGlobal:
noVal(c, it)