branch: elpa/geiser-chicken
commit caa81749a7263772d97bbe2546a4ea794e7ed497
Author: Dan Leslie <[email protected]>
Commit: Dan Leslie <[email protected]>
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.
---
geiser/emacs.scm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/geiser/emacs.scm b/geiser/emacs.scm
index e4e84c0..47e4418 100644
--- a/geiser/emacs.scm
+++ b/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)