IC: first steps towards 'nim check --def --ic:on' (#17714)
* IC: first steps towards 'nim check --def --ic:on' * IC navigator: deduplicate output lines * IC navigator: progress * IC navigator: use a different nimcache entry * IC navigator: special logic for templates/macros * IC navigator: proper error messages * IC navigator: prepare for testing code; document only what currently works somewhat
This commit is contained in:
parent
3b47a689cf
commit
67e28c07f9
11 changed files with 211 additions and 12 deletions
|
|
@ -21,7 +21,7 @@ import
|
|||
modules,
|
||||
modulegraphs, tables, lineinfos, pathutils, vmprofiler
|
||||
|
||||
import ic / [cbackend, integrity]
|
||||
import ic / [cbackend, integrity, navigator]
|
||||
from ic / ic import rodViewer
|
||||
|
||||
when not defined(leanCompiler):
|
||||
|
|
@ -54,11 +54,20 @@ proc commandGenDepend(graph: ModuleGraph) =
|
|||
' ' & changeFileExt(project, "dot").string)
|
||||
|
||||
proc commandCheck(graph: ModuleGraph) =
|
||||
graph.config.setErrorMaxHighMaybe
|
||||
defineSymbol(graph.config.symbols, "nimcheck")
|
||||
let conf = graph.config
|
||||
conf.setErrorMaxHighMaybe
|
||||
defineSymbol(conf.symbols, "nimcheck")
|
||||
semanticPasses(graph) # use an empty backend for semantic checking only
|
||||
compileProject(graph)
|
||||
|
||||
if conf.symbolFiles != disabledSf:
|
||||
case conf.ideCmd
|
||||
of ideDef: navDefinition(graph)
|
||||
of ideUse: navUsages(graph)
|
||||
of ideDus: navDefusages(graph)
|
||||
else: discard
|
||||
writeRodFiles(graph)
|
||||
|
||||
when not defined(leanCompiler):
|
||||
proc commandDoc2(graph: ModuleGraph; json: bool) =
|
||||
handleDocOutputOptions graph.config
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue