nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
ropes: Fix the behavior of `RopeBuffer.clear` when used with `to_s`.
[nit.git]
/
lib
/
standard
/
ropes.nit
diff --git
a/lib/standard/ropes.nit
b/lib/standard/ropes.nit
index
df98433
..
8d2d057
100644
(file)
--- a/
lib/standard/ropes.nit
+++ b/
lib/standard/ropes.nit
@@
-241,6
+241,10
@@
class RopeBuffer
length = 0
rpos = 0
dumped = 0
+ if written then
+ ns = new NativeString(buf_size)
+ written = false
+ end
end
redef fun substring(from, count) do