mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-28 08:54:53 +00:00
change --hint[X] => --hint:X in nim repo (avoids shell quoting issues) (#18085)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Special configuration file for the Nim project
|
||||
|
||||
hint[XDeclaredButNotUsed]:off
|
||||
hint:XDeclaredButNotUsed:off
|
||||
|
||||
define:booting
|
||||
define:nimcore
|
||||
@@ -22,5 +22,5 @@ define:useStdoutAsStdmsg
|
||||
#gc:markAndSweep
|
||||
|
||||
@if nimHasWarningObservableStores:
|
||||
warning[ObservableStores]: off
|
||||
warning:ObservableStores: off
|
||||
@end
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Special configuration file for the Nim project
|
||||
# gc:markAndSweep
|
||||
|
||||
hint[XDeclaredButNotUsed]:off
|
||||
hint:XDeclaredButNotUsed:off
|
||||
path:"$projectPath/.."
|
||||
|
||||
path:"$lib/packages/docutils"
|
||||
|
||||
@@ -13,8 +13,8 @@ cc = gcc
|
||||
# additional options always passed to the compiler:
|
||||
--parallel_build: "0" # 0 to auto-detect number of processors
|
||||
|
||||
hint[LineTooLong]=off
|
||||
#hint[XDeclaredButNotUsed]=off
|
||||
hint:LineTooLong:off
|
||||
#hint:XDeclaredButNotUsed:off
|
||||
|
||||
# Examples of how to setup a cross-compiler:
|
||||
|
||||
|
||||
@@ -47,12 +47,12 @@ Advanced options:
|
||||
an implementation defined set of suggestions.
|
||||
-w:on|off|list, --warnings:on|off|list
|
||||
turn all warnings on|off or list all available
|
||||
--warning[X]:on|off turn specific warning X on|off
|
||||
--warning:X:on|off turn specific warning X on|off.
|
||||
`warning:X` means `warning:X:on`, as with similar flags.
|
||||
--hints:on|off|list turn all hints on|off or list all available
|
||||
--hint[X]:on|off turn specific hint X on|off
|
||||
--warningAsError[X]:on|off
|
||||
turn specific warning X into an error on|off
|
||||
--hintAsError[X]:on|off turn specific hint X into an error on|off
|
||||
--hint:X:on|off turn specific hint X on|off.
|
||||
--warningAsError:X:on|off turn specific warning X into an error on|off
|
||||
--hintAsError:X:on|off turn specific hint X into an error on|off
|
||||
--styleCheck:off|hint|error
|
||||
produce hints or errors for Nim identifiers that
|
||||
do not adhere to Nim's official style guide
|
||||
|
||||
@@ -25,7 +25,7 @@ just like an ordinary procedure call with named or positional arguments. The
|
||||
available parameters depend on the invoked filter. Before version 0.12.0 of
|
||||
the language `#!` was used instead of `#?`.
|
||||
|
||||
**Hint:** With `--hint[codeBegin]:on`:option: or `--verbosity:2`:option:
|
||||
**Hint:** With `--hint:codeBegin:on`:option: or `--verbosity:2`:option:
|
||||
(or higher) while compiling or `nim check`:cmd:, Nim lists the processed code after
|
||||
each filter application.
|
||||
|
||||
|
||||
@@ -53,8 +53,8 @@ Advanced command-line switches are:
|
||||
List of warnings
|
||||
----------------
|
||||
|
||||
Each warning can be activated individually with `--warning[NAME]:on|off`:option: or
|
||||
in a `push` pragma.
|
||||
Each warning can be activated individually with `--warning:NAME:on|off`:option: or
|
||||
in a `push` pragma with `{.warning[NAME]:on|off.}`.
|
||||
|
||||
========================== ============================================
|
||||
Name Description
|
||||
@@ -77,8 +77,8 @@ User Some user-defined warning.
|
||||
List of hints
|
||||
-------------
|
||||
|
||||
Each hint can be activated individually with `--hint[NAME]:on|off`:option: or in a
|
||||
`push` pragma.
|
||||
Each hint can be activated individually with `--hint:NAME:on|off`:option: or in a
|
||||
`push` pragma with `{.hint[NAME]:on|off.}`.
|
||||
|
||||
========================== ============================================
|
||||
Name Description
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Special configuration file for the Nim project
|
||||
|
||||
hint[XDeclaredButNotUsed]:off
|
||||
hint:XDeclaredButNotUsed:off
|
||||
|
||||
define:booting
|
||||
define:nimcore
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
gc:markAndSweep
|
||||
|
||||
hint[XDeclaredButNotUsed]:off
|
||||
hint:XDeclaredButNotUsed:off
|
||||
|
||||
path:"$lib/packages/docutils"
|
||||
|
||||
|
||||
@@ -486,7 +486,7 @@ proc icTests(r: var TResults; testsDir: string, cat: Category, options: string;
|
||||
writeOnly = " --incremental:writeonly "
|
||||
readOnly = " --incremental:readonly "
|
||||
incrementalOn = " --incremental:on -d:nimIcIntegrityChecks "
|
||||
navTestConfig = " --ic:on -d:nimIcNavigatorTests --hint[Conf]:off --warnings:off "
|
||||
navTestConfig = " --ic:on -d:nimIcNavigatorTests --hint:Conf:off --warnings:off "
|
||||
|
||||
template test(x: untyped) =
|
||||
testSpecWithNimcache(r, makeRawTest(file, x & options, cat), nimcache)
|
||||
@@ -500,7 +500,7 @@ proc icTests(r: var TResults; testsDir: string, cat: Category, options: string;
|
||||
|
||||
template checkTest() =
|
||||
var test = makeRawTest(file, options, cat)
|
||||
test.spec.cmd = compilerPrefix & " check --hint[Conf]:off --warnings:off --ic:on $options " & file
|
||||
test.spec.cmd = compilerPrefix & " check --hint:Conf:off --warnings:off --ic:on $options " & file
|
||||
testSpecWithNimcache(r, test, nimcache)
|
||||
|
||||
if not isNavigatorTest:
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
discard """
|
||||
cmd: '''nim c --warningAsError[Uninit]:on --skipCfg --skipParentCfg $file'''
|
||||
cmd: '''nim c --warningAsError:Uninit:on --skipCfg --skipParentCfg $file'''
|
||||
errormsg: "use explicit initialization of 'x' for clarity [Uninit]"
|
||||
line: 24
|
||||
disabled: "true"
|
||||
|
||||
@@ -13,7 +13,7 @@ var ps: seq[Process] # compile & run 2 progs in parallel
|
||||
const nim = getCurrentCompilerExe()
|
||||
for prog in ["a", "b"]:
|
||||
ps.add startProcess(nim, "",
|
||||
["r", "--hint[Conf]=off", "--hint[Processing]=off", prog],
|
||||
["r", "--hint:Conf:off", "--hint:Processing:off", prog],
|
||||
options = {poUsePath, poDaemon, poStdErrToStdOut})
|
||||
|
||||
for p in ps:
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
discard """
|
||||
cmd: "nim check --hint[processing]:off $file"
|
||||
cmd: "nim check --hint:processing:off $file"
|
||||
errormsg: "3 is not two"
|
||||
nimout: '''t8741.nim(13, 9) Error: cannot attach a custom pragma to 'a'
|
||||
t8741.nim(29, 15) template/generic instantiation of `onlyTwo` from here
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
discard """
|
||||
cmd: "nim check --hint[Processing]:off --hint[Conf]:off $file"
|
||||
cmd: "nim check --hint:Processing:off --hint:Conf:off $file"
|
||||
errormsg: "18446744073709551615 can't be converted to int8"
|
||||
nimout: '''tcompiletime_range_checks.nim(36, 21) Error: 2147483648 can't be converted to int32
|
||||
tcompiletime_range_checks.nim(37, 23) Error: -1 can't be converted to uint64
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
discard """
|
||||
cmd: '''nim c --hint[Processing]:off $file'''
|
||||
cmd: '''nim c --hint:Processing:off $file'''
|
||||
nimout: '''
|
||||
tunused_imports.nim(11, 10) Warning: BEGIN [User]
|
||||
tunused_imports.nim(36, 10) Warning: END [User]
|
||||
|
||||
@@ -53,7 +53,7 @@ proc initConfigData(c: var TConfigData) =
|
||||
c.webdoc = @[]
|
||||
c.pdf = @[]
|
||||
c.infile = ""
|
||||
c.nimArgs = "--hint[Conf]:off --hint[Path]:off --hint[Processing]:off -d:boot "
|
||||
c.nimArgs = "--hint:Conf:off --hint:Path:off --hint:Processing:off -d:boot "
|
||||
c.gitURL = "https://github.com/nim-lang/Nim"
|
||||
c.docHTMLOutput = "doc/html"
|
||||
c.webUploadOutput = "web/upload"
|
||||
|
||||
Reference in New Issue
Block a user