bugfix: compiling after idetools usage is now possible in caas mode

This commit is contained in:
Zahary Karadjov
2013-05-05 00:42:16 +03:00
parent 519d5b834a
commit 5a2720e990
2 changed files with 20 additions and 0 deletions

View File

@@ -214,6 +214,9 @@ proc rodPass =
if optSymbolFiles in gGlobalOptions:
registerPass(rodwritePass)
proc codegenPass =
registerPass cgenPass
proc semanticPasses =
registerPass verbosePass
registerPass semPass
@@ -381,6 +384,13 @@ proc CommandSuggest =
msgs.gErrorMax = high(int) # do not stop after first error
semanticPasses()
rodPass()
if isServing:
# XXX: hacky work-around ahead
# Currently, it's possible to issue a idetools command, before
# issuing the first compile command. This will leave the compiler
# cache in a state where "no recompilation is necessary", but the
# cgen pass was never executed at all.
codegenPass()
compileProject()
if isServing:
if optDef in gGlobalOptions:

View File

@@ -0,0 +1,10 @@
main.nim
> idetools --track:main.nim,5,18 --def main.nim
strutils.toUpper
SuccessX
> idetools --track:main.nim,5,18 --def main.nim
strutils.toUpper
SuccessX
> c
SuccessX