On Tue, Mar 13, 2012 at 01:52:56AM -0700, Ray Dillinger wrote: > Does the standard really need to specify a read/write syntax for > such symbols?
Yes, it absolutely must in order to be useful and generic. > Because in writing portable code, I tend to think that if I really > want to specify a symbol whose name contains a space, I would rather > write > > (string->symbol "Foo bar") > > because it is drastically more clear in both intent and syntax, as well > as more reliable across all implementations, than any of the escaped > symbol notations under discussion. That's nice, but you can't use that as an identifier. For generated code, having the standard guarantee that arbitrary symbols be written and read back without issues is absolutely paramount, IMO. Furthermore, if one wants to be able to have an s-expression-based protocol, this is essential as well. Otherwise you can't have a client written in Scheme A and a server written in Scheme B communicate. You lose homoiconity. In my opinion, that's one of the worst things a Lisp variant can do. > While arbitrary strings can need to be converted to symbols and back > during execution of code, I'm not able to coming up with any > scenario that requires their use in source code. See above. Maybe not necessarily source code, but whenever you want to serialize arbitrary s-expressions you don't want to have to bother with the idea "can this be written at all?". That's an arbitrary limitation that serves no useful purpose. Cheers, Peter -- http://sjamaan.ath.cx -- "The process of preparing programs for a digital computer is especially attractive, not only because it can be economically and scientifically rewarding, but also because it can be an aesthetic experience much like composing poetry or music." -- Donald Knuth _______________________________________________ Scheme-reports mailing list [email protected] http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports
