On Monday 15 December 2008 07:44, Rich Hickey wrote: > On Mon, Dec 15, 2008 at 10:40 AM, Randall R Schulz <rsch...@sonic.net> wrote: > > On Friday 05 December 2008 15:36, Randall R Schulz wrote: > >> I make pretty extensive use of nested classes > >> (most significantly Enum types). > >> > >> I was wondering if it might be a good idea to > >> allow "dot" resolution to find such types. > >> > >> > >> E.g.: > >> > >> user=> tau.run.TSEvent.TSEKind > >> java.lang.ClassNotFoundException: tau.run.TSEvent.TSEKind > >> (repl-1:7) > >> > >> user=> tau.run.TSEvent$TSEKind > >> tau.run.TSEvent$TSEKind > >> > >> > >> In Java code I can refer to TSEKind as tau.run.TSEvent.TSEKind so > >> it seems natural to wonder if it would be reasonable to expect the > >> same notation to resolve to the same type in Clojure? > > > > Everyone gives this a "meh"?? > > Dot is too overloaded in Java, and overloaded enough in Clojure. This > one doesn't seem too important to me.
Actually, I don't think this is really overloading. It still amounts to selecting a member of a namespace (abstractly speaking, whether package or class). As to importance, I guess that depends on how much use one makes of (named) inner classes. I have quite a few of them in my system, and the dollar signs are ugly and easy to forget (until, of course, you try to compile your code). I can also imagine that when trying to search through code for uses of a particular nested type in a joint Clojure / Java project the regular expressions get that much more messy. > Rich Randall Schulz --~--~---------~--~----~------------~-------~--~----~ 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 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 -~----------~----~----~----~------~----~------~--~---