fixes #2420; negative indexing for slicing is obsolete (breaking change!)
This commit is contained in:
parent
46fb0e0bac
commit
2b80d75aa2
8 changed files with 82 additions and 79 deletions
|
|
@ -1281,7 +1281,7 @@ proc semStmtList(c: PContext, n: PNode, flags: TExprFlags): PNode =
|
|||
var tryStmt = newNodeI(nkTryStmt, n.sons[i].info)
|
||||
var body = newNodeI(nkStmtList, n.sons[i].info)
|
||||
if i < n.sonsLen - 1:
|
||||
body.sons = n.sons[(i+1)..(-1)]
|
||||
body.sons = n.sons[(i+1)..n.len-1]
|
||||
tryStmt.addSon(body)
|
||||
tryStmt.addSon(deferPart)
|
||||
n.sons[i] = semTry(c, tryStmt)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue