make case-object transitions explicit, make unknownLineInfo a const, replace a few magic numbers with consts (#13170)

This commit is contained in:
Jasper Jenkins 2020-01-17 01:34:32 -08:00 • committed by Andreas Rumpf
commit 796aafe7e0
35 changed files with 182 additions and 203 deletions

View file

@ -416,7 +416,7 @@ proc semAfterMacroCall(c: PContext, call, macroResult: PNode,
# More restrictive version.
result = semExprWithType(c, result, flags)
of tyTypeDesc:
if result.kind == nkStmtList: result.kind = nkStmtListType
if result.kind == nkStmtList: result.transitionSonsKind(nkStmtListType)
var typ = semTypeNode(c, result, nil)
if typ == nil:
localError(c.config, result.info, "expression has no type: " &