Files
Nim/config/config.nims
Timothee Cour f77dea01fd define nimVersion automatically and avoid needing -d:nimVersion140 (#18726)
* define `nimVersion` and avoid needing -d:nimVersion140

* fix changelog
2021-10-17 08:37:52 +02:00

19 lines
579 B
Nim

# this config.nims also needs to exist to prevent future regressions, see #9990
cppDefine "errno"
cppDefine "unix"
when defined(nimStrictMode):
# xxx add more flags here, and use `-d:nimStrictMode` in more contexts in CI.
# pending bug #14246, enable this:
# when defined(nimHasWarningAsError):
# switch("warningAsError", "UnusedImport")
when defined(nimHasHintAsError):
# switch("hint", "ConvFromXtoItselfNotNeeded")
switch("hintAsError", "ConvFromXtoItselfNotNeeded")
# future work: XDeclaredButNotUsed
switch("define", "nimVersion:" & NimVersion)