implemented a new localPassc pragma (#12706)
This commit is contained in:
parent
c0eeea4f3c
commit
64e8f050e1
7 changed files with 48 additions and 12 deletions
|
|
@ -46,7 +46,7 @@ const
|
|||
wWarnings, wHints,
|
||||
wLineDir, wStackTrace, wLineTrace, wOptimization, wHint, wWarning, wError,
|
||||
wFatal, wDefine, wUndef, wCompile, wLink, wLinksys, wPure, wPush, wPop,
|
||||
wPassl, wPassc,
|
||||
wPassl, wPassc, wLocalPassc,
|
||||
wDeadCodeElimUnused, # deprecated, always on
|
||||
wDeprecated,
|
||||
wFloatChecks, wInfChecks, wNanChecks, wPragma, wEmit, wUnroll,
|
||||
|
|
@ -998,6 +998,11 @@ proc singlePragma(c: PContext, sym: PSym, n: PNode, i: var int,
|
|||
let s = expectStrLit(c, it)
|
||||
extccomp.addCompileOption(c.config, s)
|
||||
recordPragma(c, it, "passc", s)
|
||||
of wLocalPassc:
|
||||
assert sym != nil and sym.kind == skModule
|
||||
let s = expectStrLit(c, it)
|
||||
extccomp.addLocalCompileOption(c.config, s, toFullPathConsiderDirty(c.config, sym.info.fileIndex))
|
||||
recordPragma(c, it, "localpassl", s)
|
||||
of wPush:
|
||||
processPush(c, n, i + 1)
|
||||
result = true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue