Probably you slightly misunderstood what I mean. Consider this scenario: I've set up a project which uses a new library with non-standart indent. I've connected to swank and compiled it. Then I'm calling some clojure-mode-update-indent function, which walks through all loaded namespaces and collects :indent metadata (on the clojure side) and saves appropriate define-clojure-indent form somewhere in config file (on the elisp side). After that I have all macros indented properly.
It's better than manually writing define-clojure-indent form because it's tool-agnostic; say, CCW can use the same data, so library maintainers only have to add {:indent :defn} to their defmacros. суббота, 31 марта 2012 г. 2:32:35 UTC+6 пользователь Phil Hagelberg написал: > > Vinzent <ru.vinz...@gmail.com> writes: > > > I'm not sure how I feel about indentation rules > > changing depending on whether slime is active or not. > > > > What I was thinking, is that there'd be some function which would > > collect and save indentation metadata, so it can be used later. Thus, > > active slime connection required only the first time one uses a > > library with non-standart indentation rules. > > Currently clojure-mode operates on each file in isolation. As soon as > you start "remembering" macro indentation, you're back in a > non-deterministic state where indentation depends on the history of > which files you've visited in the current Emacs session. > > You could make it work just for the macros in a single file, but that > doesn't seem very valuable. > > -Phil > > -- 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