Hi Chas,

This is a questionable proposal. It:
>
> * introduces completely orthogonal, transient concerns (presentation) into
> code, ideally a canonical, long-lived source-of-truth
>

Yes, I'm ok with that. No one is better equipped to define a macro's
indentation than it's author, and the metadata is the same place that
carries other info like arglists or docstrings.

Then again, maybe I'm just used to it because emacs-lisp uses a similar
system.


> * sets up a bikeshed at the top of every def* form
>

As bozhidar mentioned, this will only go on defs which deserve special
indentation (which is tipically just macros and not all of them). And even
then, in most cases the spec is just an integer (in my examples above I
used the most complex macros I could find in clojure.core). For instance,
the spec for let, loop, and doseq is 1, the spec for condp and catch is 2.

* adopts idiosyncratic implementation details of a particular editor's
> language support (the defrecord example's :indent is particularly obtuse
> IMO, even if you are aware of how clojure-mode is implemented)
>

Actually, the proposed spec is different from what clojure-mode is
currently using and won't work with the current release. But still, there's
no doubt I may have been influenced by what made more sense for me to
implement, that's precisely why I brought it here. :-)

If there's a better way to define it, I'd like to hear.


> I *think* I coined the "always two spaces" shorthand for the (admittedly,
> minority) position that list forms should be formatted completely
> regularly, so as to:
>
> * make formatting a trivial operation, not requiring any "real" reading
> * eliminate this entire topic
>
> Here's the first time I talked about this IIRC:
> https://groups.google.com/forum/#!msg/clojuredev-users/NzKTeY722-I/3hmNvJulcksJ
>

The spec does not define how many spaces should be used in indentation. It
just says "the author of this macro declared the first 2 args as special".
Any editor will let the user configure if they want "always 2 spaces" or if
they want "1-2-4".

-- 
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 unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to