diff options
author | Arne Döring <arne.doering@gmx.net> | 2017-08-07 18:21:21 +0200 |
---|---|---|
committer | Arne Döring <arne.doering@gmx.net> | 2017-08-07 18:21:21 +0200 |
commit | 54808ab12fcbf8cc253129ed03f560fc6dd2648e (patch) | |
tree | f87094474da3df24bd94b393dcbe838290ed13a5 /compiler | |
parent | 3bf1f019a76c6fee5553a7daf7d984cfd39cfb04 (diff) | |
download | Nim-54808ab12fcbf8cc253129ed03f560fc6dd2648e.tar.gz |
don't filter '\0' characters in string generation
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/rodutils.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rodutils.nim b/compiler/rodutils.nim index 3a90a207c..6e77e6b8f 100644 --- a/compiler/rodutils.nim +++ b/compiler/rodutils.nim @@ -22,7 +22,7 @@ proc toStrMaxPrecision*(f: BiggestFloat, literalPostfix = ""): string = else: result = "-INF" else: var buf: array[0..80, char] - let newLen = c_snprintf(buf.cstring, buf.len.uint, "%#.16e%s", f, literalPostfix.cstring) + discard c_snprintf(buf.cstring, buf.len.uint, "%#.16e%s", f, literalPostfix.cstring) result = $buf.cstring proc encodeStr*(s: string, result: var string) = |