diff options
author | Araq <rumpf_a@web.de> | 2019-04-09 11:21:35 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2019-04-09 11:21:35 +0200 |
commit | 0a01f5b655db57e9ec6484b1bd9080c251e5769a (patch) | |
tree | 215c0060b044eb8743429ab3dadccf793daaedaa /lib/core | |
parent | f44e1e2214b2d40f078409aa42418da76a5a6d44 (diff) | |
download | Nim-0a01f5b655db57e9ec6484b1bd9080c251e5769a.tar.gz |
strs.nim: fixed a silly typo
Diffstat (limited to 'lib/core')
-rw-r--r-- | lib/core/strs.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/core/strs.nim b/lib/core/strs.nim index ccc261d95..f02757070 100644 --- a/lib/core/strs.nim +++ b/lib/core/strs.nim @@ -120,7 +120,7 @@ proc toNimStr(str: cstring, len: int): NimStringV2 {.compilerProc.} = if len > 0: # we are about to append, so there is no need to copy the \0 terminator: copyMem(unsafeAddr p.data[0], str, len) - result = NimStringV2(len: 0, p: p) + result = NimStringV2(len: len, p: p) proc cstrToNimstr(str: cstring): NimStringV2 {.compilerRtl.} = if str == nil: toNimStr(str, 0) |