On Sun, Jul 1, 2012 at 10:09 AM, David A. Wheeler <[email protected]>wrote:

> Alan Manuel Gloria <[email protected]> said:
>
> >This seems to privelege QUOTE et al. too much.  Or should they indeed be
> privileged?
>
> I agree with your intuition.  Privileging quote isn't *necessarily* bad,
> but we should strive for the principle of least surprise, and this specific
> proposal seems like a "weird exception" that I think would make the format
> harder, not easier, to understand.   In particular, you pointed out that:
>
> > '
> > ..x
> > ..y
> > => yields (quote x y), which, while wrong, is still what I expect.  It's
> not clear from this alone what it should mean.
>
> I agree with you.  Having this expression yield "(quote (x y))" would make
> it very inconsistent with the non-quote case, and I think we should strive
> for consistency.
>

Well if it's about consistency, a basic inspection of the QUOTE and GROUP
productions suggest that they are treated differently.

In particular (again initial . means spaces):

group group x
..y

' ' x
..y

the first yields (group x y), the second yields (quote (quote (x y)))

How about instead considering the quote character as a straight
abbreviation for the quote symbol?

To differentiate, in current s-expressions the quote character is actually
a special reader syntax where it means "wrap the next expression _x_ in the
list (quote _x_)".

My proposal is that (outside of modern-expressions) it simply means "the
quote symbol".

So:

' '
..x

==>

quote quote
..x

==>

(quote quote x)

---

Also:

'
..'
....x

==>

quote
..quote
....x

==>

(quote (quote x))

Whatcha think?

Sincerely,
AmkG
------------------------------------------------------------------------------
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
[email protected]
https://lists.sourceforge.net/lists/listinfo/readable-discuss

Reply via email to