compiler/sem*: improve lineinfo for qualified and generic procs (#10427)
Previously the compiler will believe these are where `newSeq` symbol
starts:
newSeq[int]()
^
system.newSeq[int]()
^
This commit moves them back to:
newSeq[int]()
^
system.newSeq[int]()
^
This commit is contained in:
parent
f1a841c605
commit
e962be8981
5 changed files with 56 additions and 19 deletions
|
|
@ -1171,9 +1171,10 @@ proc semSym(c: PContext, n: PNode, sym: PSym, flags: TExprFlags): PNode =
|
|||
onUse(n.info, s)
|
||||
result = newSymNode(s, n.info)
|
||||
else:
|
||||
markUsed(c.config, n.info, s, c.graph.usageSym)
|
||||
onUse(n.info, s)
|
||||
result = newSymNode(s, n.info)
|
||||
let info = getCallLineInfo(n)
|
||||
markUsed(c.config, info, s, c.graph.usageSym)
|
||||
onUse(info, s)
|
||||
result = newSymNode(s, info)
|
||||
|
||||
proc builtinFieldAccess(c: PContext, n: PNode, flags: TExprFlags): PNode =
|
||||
## returns nil if it's not a built-in field access
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue