nimsuggest: better logging for EPC mode

This commit is contained in:
Andreas Rumpf
2017-02-20 09:54:20 +01:00
parent 2df5a6f863
commit 1ec96d7353

View File

@@ -403,8 +403,10 @@ proc mainThread(graph: ModuleGraph; cache: IdentCache) =
it = it.next
proc wrHook(line: string) {.closure.} =
if gMode == mepc: discard
else: writelnToChannel(line)
if gMode == mepc:
if gLogging: logStr(line)
else:
writelnToChannel(line)
msgs.writelnHook = wrHook
suggestionResultHook = sugResultHook