adjust debugger to print smaller version of values to improve performance

This commit is contained in:
John Griffin 2011-08-31 14:24:25 -05:00 committed by Robby Findler
parent 168291c89d
commit bdee3509b7

View File

@ -132,6 +132,10 @@
(> size (vector-length v)))
'...
(truncate-value (vector-ref v i) size (sub1 depth)))))]
[(bytes? v)
(if (> (bytes-length v) size)
(subbytes v 0 size)
v)]
[else v]))
(define filename->defs
@ -1141,7 +1145,7 @@
(for-each
(lambda (name/value)
(let ([name (format "~a" (syntax-e (first name/value)))]
[value (format " => ~s\n" (second name/value))])
[value (format " => ~s\n" (truncate-value (second name/value) 100 5))])
(send variables-text insert name)
(send variables-text change-style bold-sd
(- (send variables-text last-position) (string-length name))