summaryrefslogtreecommitdiff
path: root/scheme
diff options
context:
space:
mode:
authorDan Leslie <dan@ironoxide.ca>2015-08-28 16:47:12 -0700
committerDan Leslie <dan@ironoxide.ca>2015-08-28 16:47:12 -0700
commitb232512c4d7bffae7f2ac8302c3136a637910264 (patch)
treee28c4d0938ad31a237b9a244b49afaeda15b7fed /scheme
parent0f66c250245af1348a3ee5a698c69ec4245e2194 (diff)
downloadgeiser-guile-b232512c4d7bffae7f2ac8302c3136a637910264.tar.gz
geiser-guile-b232512c4d7bffae7f2ac8302c3136a637910264.tar.bz2
Use pretty-print instead of write with Chicken
Emacs chokes on buffers with very long lines. Use of pretty-print instead of write causes most incidents of long lines to be avoided by use of better formatting. This fixes jaor/geiser#64 for Chicken, and appears to greatly speed up completions in the general case for Chicken.
Diffstat (limited to 'scheme')
-rw-r--r--scheme/chicken/geiser/emacs.scm4
1 files changed, 2 insertions, 2 deletions
diff --git a/scheme/chicken/geiser/emacs.scm b/scheme/chicken/geiser/emacs.scm
index e4e84c0..47e4418 100644
--- a/scheme/chicken/geiser/emacs.scm
+++ b/scheme/chicken/geiser/emacs.scm
@@ -259,11 +259,11 @@
(set! result
(cond
((list? result)
- (map (lambda (v) (with-output-to-string (lambda () (write v)))) result))
+ (map (lambda (v) (with-output-to-string (lambda () (pretty-print v)))) result))
((eq? result (if #f #t))
(list output))
(else
- (list (with-output-to-string (lambda () (write result)))))))
+ (list (with-output-to-string (lambda () (pretty-print result)))))))
(let ((out-form
`((result ,@result)