diff options
author | Araq <rumpf_a@web.de> | 2013-12-08 01:47:07 +0100 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2013-12-08 01:47:07 +0100 |
commit | 29357ab556a25ea75d0cf837eace079b46d51fc8 (patch) | |
tree | 9bd907fa9407da13b30d84f1c87064507b1a4a1f /lib | |
parent | 430c8d8b526c6f94a789db3362e9d2807d81e61d (diff) | |
download | Nim-29357ab556a25ea75d0cf837eace079b46d51fc8.tar.gz |
more tests are green
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pure/encodings.nim | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/pure/encodings.nim b/lib/pure/encodings.nim index ce4238409..bc849bfe8 100644 --- a/lib/pure/encodings.nim +++ b/lib/pure/encodings.nim @@ -14,15 +14,15 @@ import os, parseutils, strutils when not defined(windows): type - TConverter = object {.pure, final.} + TConverter = object PConverter* = ptr TConverter ## can convert between two character sets - + else: type TCodePage = distinct int32 - PConverter* = object {.pure.} + PConverter* = object dest, src: TCodePage - + type EInvalidEncoding* = object of EInvalidValue ## exception that is raised ## for encoding errors @@ -425,7 +425,7 @@ else: dst = cast[cstring](cast[int](cstring(result)) + offset) outLen = len(result) - offset else: - OSError() + OSError(lerr.TOSErrorCode) # iconv has a buffer that needs flushing, specially if the last char is # not '\0' discard iconv(c, nil, nil, dst, outlen) |