fix #20248;fix #6215;turns into simple CT error (#21141)
This commit is contained in:
parent
886572a516
commit
40b5c4c4c3
2 changed files with 16 additions and 0 deletions
|
|
@ -328,6 +328,8 @@ proc semRange(c: PContext, n: PNode, prev: PType): PType =
|
|||
proc semArrayIndex(c: PContext, n: PNode): PType =
|
||||
if isRange(n):
|
||||
result = semRangeAux(c, n, nil)
|
||||
elif n.kind == nkInfix and n[0].kind == nkIdent and n[0].ident.s == "..<":
|
||||
result = errorType(c)
|
||||
else:
|
||||
let e = semExprWithType(c, n, {efDetermineType})
|
||||
if e.typ.kind == tyFromExpr:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue