Allow hint and warning to specify its loc info (#8771)
Let's bring those to feature-parity with `error`.
This commit is contained in:
parent
6e83746caa
commit
5cd152bfda
4 changed files with 40 additions and 12 deletions
|
|
@ -1192,10 +1192,10 @@ proc genMagic(c: PCtx; n: PNode; dest: var TDest; m: TMagic) =
|
|||
else: internalAssert c.config, false
|
||||
of mNHint:
|
||||
unused(c, n, dest)
|
||||
genUnaryStmt(c, n, opcNHint)
|
||||
genBinaryStmt(c, n, opcNHint)
|
||||
of mNWarning:
|
||||
unused(c, n, dest)
|
||||
genUnaryStmt(c, n, opcNWarning)
|
||||
genBinaryStmt(c, n, opcNWarning)
|
||||
of mNError:
|
||||
if n.len <= 1:
|
||||
# query error condition:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue