projects
/
mit-scheme.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f96712e
)
Change string-copy to return legacy string only if arg is also legacy.
author
Chris Hanson
<org/chris-hanson/cph>
Sat, 22 Apr 2017 07:20:30 +0000
(
00:20
-0700)
committer
Chris Hanson
<org/chris-hanson/cph>
Sat, 22 Apr 2017 07:20:30 +0000
(
00:20
-0700)
src/runtime/ustring.scm
patch
|
blob
|
history
diff --git
a/src/runtime/ustring.scm
b/src/runtime/ustring.scm
index 4acf9bff8b9bcab7f4c559a5130c157c09e8231d..3607bfd17a549534f4de3efcb034a3f39cb249e8 100644
(file)
--- a/
src/runtime/ustring.scm
+++ b/
src/runtime/ustring.scm
@@
-370,8
+370,7
@@
USA.
(lambda (string start end)
(let* ((n (fix:- end start))
(to
- (if (or (fix:= 1 (ustring-cp-size string))
- (fix:< (%general-max-cp string start end) #x100))
+ (if (legacy-string? string)
(legacy-string-allocate n)
(mutable-ustring-allocate n))))
(%general-copy! to 0 string start end)