[plt-scheme] Displaying full error in MzScheme

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Fri Mar 5 09:37:49 EST 2004

At Fri, 5 Mar 2004 09:07:19 -0500 (EST), Andre van Tonder wrote:
> I am doing some heavy macro programming in MzScheme (via emacs).
> Unfortunately, whenever a syntax error occurs, only the first two lines of
> the offending expression (which can be long) is printed in the MzScheme
> repl, which is making debugging very difficult.  Is there a way to have
> MzScheme print the full expression when a syntax error occurs? 

You can turn up the error width through the `error-print-width'
parameter.

 > (error-print-width)
 100
 > (eval `(lambda ,(make-string 1000 #\a)))
 lambda: bad syntax in: (lambda "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
 > (error-print-width 500)
 > (eval `(lambda ,(make-string 1000 #\a)))
 lambda: bad syntax in: (lambda "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 aaaaaaaaaaaaaaaaaaaaaaa...

Matthew



Posted on the users mailing list.