ic navigator tests (#17735)

* IC navigator: first basic test
This commit is contained in:
Andreas Rumpf 2021-04-16 12:20:43 +02:00 • committed by GitHub
commit 606288974f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 54 additions and 14 deletions

View file

@ -79,7 +79,7 @@ proc usage(c: var NavContext; info: PackedLineInfo; isDecl: bool) =
file = os.extractFilename file
toLocation(m, file, info.line.int, info.col.int + ColOffset)
if not c.alreadyEmitted.containsOrIncl(m):
echo (if isDecl: "def" else: "usage"), c.outputSep, m
msgWriteln c.g.config, (if isDecl: "def" else: "usage") & c.outputSep & m
proc list(c: var NavContext; tree: PackedTree; sym: ItemId) =
for i in 0..high(tree.nodes):