> I think comments should nest iff they nest in that language *without* our
readers. That is, if #|...|# nests in the underlying language, then it
should in our reader. If it doesn't, it shouldn't. Remember, we're trying
to maximize backwards compatibility, so we shouldn't change the semantics
of stuff we don't *have* to.
Ah, so you're implementing something already provided by a language! I was
under the impression that these were something new for sweet-expressions.
I'm glad to see that they are done right in Scheme, as it is! :-) (Of
course, it probably shouldn't come as a surprise. This *is* a Lisp
community we're talking about...)
To the best of my knowledge, Common Lisp does not have multi-line comments,
so I don't think this is going to be an issue for Common Lisp.
On Thu, Aug 2, 2012 at 4:54 PM, David A. Wheeler <dwhee...@dwheeler.com>wrote:
> Alan Manuel Gloria:
> > The comments themselves remove text in the following manner:
> >
> > #|.. #|...|#...|# nests
> >
> > #!..!# doesn't nest, as per Guile behavior
>
> I think that's perfect. As much as possible we should be
> backwards-compatible, and this fits the bill.
>
> > #; x y z removes the x (only c-expressions/n-expressions are removed).
> > Sorry, but it gets *really* difficult to make this work at the
> > t-expression level - you need something like the current quote
> > handling to make it remove t-expressions! And of course another tag
> > separate from comment-tag.
>
> I think that's exactly the right decision.
>
> The phrase:
> #; x y z
> *could* be interpreted as "comment (x y z)" or "comment x".
>
> But as you noted, the implementation challenges would be hideous. Not
> only that, but it seems to me that a user would expect that:
>
> x #; y z
>
> Would be interpreted as "(x z)".
>
> So I think the better (as well as easier) interpretation is that #;
> comments out the following *neoteric* datum.
>
> Now, that does raise the question of how to comment out datums that are
> indented. But to be honest, ; does a fine job. If indentation is active,
> it's trivial to find the matching END line. So it's not clear that we need
> any additional mechanisms.
>
> > Will fix the incorrect handling of multiline comments in the middle of
> > lines. They should only act as SPLIT when at the start of line, to
> > handle stuff like....
>
> That sounds right, too.
>
> --- David A. Wheeler
>
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Readable-discuss mailing list
Readable-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/readable-discuss