How about using a and b instead of ( ) so we could have faab which would be the equivalent of (f a) so it would rule out symbolnames with an a in any place but the first it, also we could go for less used characters as I don't know ¥ and µ for example so that would not be half as fun I think. -- Heinz N. Gies he...@licenser.net http://licenser.net
On Dec 29, 2011, at 18:03, Mark Rathwell wrote: > The thing about lisps, though, is that code and data are represented > with the same structure. Adding sugar that makes them appear to be > different things would not help anyone, especially the beginner. It > will make grasping macros, among other things, much more difficult > down the road. Getting used to the syntax is, for practical reasons, > a necessary, and short, process, and giving new users a way to bypass > that would hurt more than it helps. (Not to mention the effect on > experienced users of having to now deal with this additional syntax in > code in the wild.) > > That said, don't let me stop you from having fun and learning with > this little experiment ;) > > On Thu, Dec 29, 2011 at 11:35 AM, Louis Yu Lu <louisy...@gmail.com> wrote: >> Agree on looking from the angle of data structure and their internal >> presentation. But conceptually, [] and {} are just syntax sugars: >> [x y] -> (vector x y) >> {x y} -> (hash-map x y) >> #{x y} -> (hash-set x y) >> The 2 element structures are all become 3 element lists. >> >> Louis >> >> On Dec 29, 7:03 am, James Reeves <jree...@weavejester.com> wrote: >>> On 29 December 2011 04:49, Louis Yu Lu <louisy...@gmail.com> wrote: >>> >>>> Instead of using overloaded (), may be f[x] will cause less trouble, >>>> and more inline with clojure's syntax as [ ] already being used for >>>> defining the arguments of the function. >>> >>> I think you need to look at this from a slightly different angle. >>> >>> In Clojure, as in all Lisps, code is represented by data structures. >>> In Clojure, (x y) is a linked list of two elements, [x y] is a vector, >>> and {x y} a map. You need to think about Clojure code in terms of the >>> data structures beneath. >>> >>> So you're proposing that x[y] be considered a two-element list. This >>> is an unusual syntax for defining a list in any language I know, and >>> looks confusingly similar to a single element followed by a vector. >>> >>> Try not to ask the question, "What syntax is good for representing a >>> function call?" and instead ask, "What syntax is good for representing >>> a linked list of elements?" >>> >>> - James >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Clojure" group. >> To post to this group, send email to clojure@googlegroups.com >> Note that posts from new members are moderated - please be patient with your >> first post. >> To unsubscribe from this group, send email to >> clojure+unsubscr...@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/clojure?hl=en > > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to clojure@googlegroups.com > Note that posts from new members are moderated - please be patient with your > first post. > To unsubscribe from this group, send email to > clojure+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en