On 14 Nov 2009, at 09:45, Mark Engelberg wrote: > In general, I really hate it when it's difficult to tell what parts of > an API are the things that the end-user is really supposed to call, > and what part of the data you're supposed to access directly versus an > accessor method. It bugs me when I call (:real complex) to extract
I agree. The distinction should be clear, even though not enforced by the language. A privacy indication that would fit well with the rest of Clojure is to tag the field name in the deftype with the "private" metadata field. The question is just how to make this information accessible to IDEs and documentation tools. In fact, the first question is how an IDE can get any information about the fields of a type. There doesn't seem to be a documented way to do it. One source would be the doc string of the constructor function. Konrad. -- 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