add nimHasWarningX and nimHasHintX defines for feature detection purposes
This commit is contained in:
parent
ae0255ea67
commit
1546826006
1 changed files with 6 additions and 0 deletions
|
|
@ -13,6 +13,7 @@ import
|
|||
strtabs, platform, strutils, idents
|
||||
|
||||
from options import Feature
|
||||
from lineinfos import HintsToStr, WarningsToStr
|
||||
|
||||
const
|
||||
catNone = "false"
|
||||
|
|
@ -83,3 +84,8 @@ proc initDefines*(symbols: StringTableRef) =
|
|||
defineSymbol("nimHasNilSeqs")
|
||||
for f in low(Feature)..high(Feature):
|
||||
defineSymbol("nimHas" & $f)
|
||||
|
||||
for s in WarningsToStr:
|
||||
defineSymbol("nimHasWarning" & s)
|
||||
for s in HintsToStr:
|
||||
defineSymbol("nimHasHint" & s)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue