Use ^ instead of - in slices

This commit is contained in:
def 2015-03-27 11:49:28 +01:00
commit 64903e7050
10 changed files with 93 additions and 93 deletions

View file

@ -2874,7 +2874,7 @@ when hostOS != "standalone":
##
## .. code-block:: nim
## var s = "abcdef"
## s[1 .. -2] = "xyz"
## s[1 .. ^2] = "xyz"
## assert s == "axyzf"
var a = x.a
var L = x.b - a + 1