fix #2844 #3911; add --spellsuggest to suggest symbols in scope with similar spellings on undefined symbol error (#16067)
* add --spellsuggest to suggest symbols in scope with similar spellings on undefined symbol errors * implement --spellsuggest with 0 arguments
This commit is contained in:
parent
d5eb658034
commit
48eab5370a
9 changed files with 178 additions and 32 deletions
|
|
@ -407,6 +407,7 @@ proc resolveOverloads(c: PContext, n, orig: PNode,
|
|||
|
||||
if overloadsState == csEmpty and result.state == csEmpty:
|
||||
if efNoUndeclared notin flags: # for tests/pragmas/tcustom_pragma.nim
|
||||
# xxx adapt/use errorUndeclaredIdentifierHint(c, n, f.ident)
|
||||
localError(c.config, n.info, getMsgDiagnostic(c, flags, n, f))
|
||||
return
|
||||
elif result.state != csMatch:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue