From: Chris Hanson Date: Wed, 29 Mar 2017 05:02:22 +0000 (-0700) Subject: Fix string-for-primitive: it wasn't handling slices. X-Git-Tag: mit-scheme-pucked-9.2.12~158^2~63 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=b949d2c1f88fddcaced2e2126ebfa41813022f31;p=mit-scheme.git Fix string-for-primitive: it wasn't handling slices. --- diff --git a/src/runtime/ustring.scm b/src/runtime/ustring.scm index 8c236b8df..6a235e6b9 100644 --- a/src/runtime/ustring.scm +++ b/src/runtime/ustring.scm @@ -1648,8 +1648,8 @@ USA. %full-string-ref string 0 end) to) (string->utf8 string)))) - (else - (error:not-a string? string 'string-for-primitive)))) + ((slice? string) (string->utf8 string)) + (else (error:not-a string? string 'string-for-primitive)))) (define-integrable (copy-loop to-set! to at from-ref from start end) (do ((i start (fix:+ i 1))