[plt-scheme] Request for pretty-printing in webserver

From: MJ Ray (markj at cloaked.freeserve.co.uk)
Date: Tue Apr 1 18:05:27 EST 2003

Eli Barzilay <eli at barzilay.org> wrote:
>> 2. The semantics of spaces in XML are rather tricky, and the server
>>    didn't want to introduce errors (since pretty-printing
>>    fundamentally is about introducing spaces).
> [...] places where you space matters (eg <pre>), and places
> where you want your output to look in a certain way (spaces or
> newlines).  Also, it knows not to put spaces or newlines in the wrong
> place -- right after an openning tag.

Are you sure that you've done this correctly, Eli?  In general, it is
safe to add additional whitespace to existing whitespace groups outside
of certain tags, but not to add new whitespace groups.

But that's only for html and the webserver generates XML in general.
Whitespace there may be significant depending on the styling, IIRC,
so it's never safe to add whitespace without the programmer's approval.
In any case, is a pipe through a pretty printer when you want to debug
so much effort that it's worth doing more processing and using more
network for all other cases?

My Opinion Only, as ever.
MJR   http://mjr.towers.org.uk/   IM: slef at jabber.at
      This is my home web site.   This for Jabber Messaging.

How's my writing? Let me know via any of my contact details.

Posted on the users mailing list.