small cleanups
This commit is contained in:
parent
4fc575bc26
commit
1342798cc7
2 changed files with 3 additions and 5 deletions
|
|
@ -180,9 +180,7 @@ proc readLine*(s: PStream): TaintedString =
|
||||||
if c == '\c':
|
if c == '\c':
|
||||||
c = readChar(s)
|
c = readChar(s)
|
||||||
break
|
break
|
||||||
if c == '\b':
|
if c == '\L' or c == '\0':
|
||||||
result.string.setLen(result.len - 1)
|
|
||||||
elif c == '\L' or c == '\0':
|
|
||||||
break
|
break
|
||||||
else:
|
else:
|
||||||
result.string.add(c)
|
result.string.add(c)
|
||||||
|
|
|
||||||
|
|
@ -186,9 +186,9 @@ when not defined(niminheritable):
|
||||||
|
|
||||||
when not defined(JS) and not defined(NimrodVM):
|
when not defined(JS) and not defined(NimrodVM):
|
||||||
type
|
type
|
||||||
TGenericSeq* {.compilerproc, pure, inheritable.} = object
|
TGenericSeq {.compilerproc, pure, inheritable.} = object
|
||||||
len, reserved: int
|
len, reserved: int
|
||||||
PGenericSeq* {.exportc.} = ptr TGenericSeq
|
PGenericSeq {.exportc.} = ptr TGenericSeq
|
||||||
# len and space without counting the terminating zero:
|
# len and space without counting the terminating zero:
|
||||||
NimStringDesc {.compilerproc, final.} = object of TGenericSeq
|
NimStringDesc {.compilerproc, final.} = object of TGenericSeq
|
||||||
data: array[0..100_000_000, char]
|
data: array[0..100_000_000, char]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue