diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2017-09-15 21:12:59 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2017-09-15 21:12:59 +0200 |
commit | ecf1424456bd95167ac0e1e721307032e22d172f (patch) | |
tree | 61781a1a7f4a037cfe88afc0988555e0b17d9782 /lib/pure/strutils.nim | |
parent | 0fe2a83dda25d682f04f7af0f73a50c45362c79f (diff) | |
parent | 8ea78b1bc9dc0b4d883b4f0750ee84e93605b82a (diff) | |
download | Nim-ecf1424456bd95167ac0e1e721307032e22d172f.tar.gz |
Merge branch 'devel' into araq
Diffstat (limited to 'lib/pure/strutils.nim')
-rw-r--r-- | lib/pure/strutils.nim | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/pure/strutils.nim b/lib/pure/strutils.nim index 2f2b89955..b39d3b691 100644 --- a/lib/pure/strutils.nim +++ b/lib/pure/strutils.nim @@ -776,7 +776,8 @@ proc countLines*(s: string): int {.noSideEffect, ## ## In this context, a line is any string seperated by a newline combination. ## A line can be an empty string. - var i = 1 + result = 1 + var i = 0 while i < s.len: case s[i] of '\c': |