Allow noreturn procs with void type (#6973)
This commit is contained in:
parent
2b3ec0a7c6
commit
53cf0b2c24
2 changed files with 5 additions and 1 deletions
|
|
@ -771,7 +771,7 @@ proc singlePragma(c: PContext, sym: PSym, n: PNode, i: int,
|
|||
of wNoreturn:
|
||||
noVal(it)
|
||||
incl(sym.flags, sfNoReturn)
|
||||
if sym.ast[paramsPos][0].kind != nkEmpty:
|
||||
if sym.typ[0] != nil:
|
||||
localError(sym.ast[paramsPos][0].info, errNoReturnWithReturnTypeNotAllowed)
|
||||
of wDynlib:
|
||||
processDynLib(c, it, sym)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue