diff --git a/pkgs/gui-pkgs/gui-test/tests/gracket/editor.rktl b/pkgs/gui-pkgs/gui-test/tests/gracket/editor.rktl index dd454e76d7..901d15cbc0 100644 --- a/pkgs/gui-pkgs/gui-test/tests/gracket/editor.rktl +++ b/pkgs/gui-pkgs/gui-test/tests/gracket/editor.rktl @@ -648,7 +648,17 @@ (error 'notifications "too weak? ~e" count)) (unless (<= 0 count2 (/ N 2)) (error 'notifications "not weak enough? ~e" count2))) - + +;; ---------------------------------------- +;; make sure splitting a large string snip works: + +(void + (send (make-object string-snip% (make-string 100000 #\a)) + split + 50000 + (box #f) + (box #f))) + ;; ---------------------------------------- ;; No # checks on certain class instances diff --git a/pkgs/snip-pkgs/snip-lib/racket/snip/private/snip.rkt b/pkgs/snip-pkgs/snip-lib/racket/snip/private/snip.rkt index 2381d6c4a9..13078c42cf 100644 --- a/pkgs/snip-pkgs/snip-lib/racket/snip/private/snip.rkt +++ b/pkgs/snip-pkgs/snip-lib/racket/snip/private/snip.rkt @@ -529,7 +529,7 @@ (let ([s (string-snip-buffer snip)]) (unless ((string-length s) . >= . position) - (set-string-snip-buffer! s (make-string position)))) + (set-string-snip-buffer! snip (make-string position)))) (string-copy! (string-snip-buffer snip) 0