I write such code like this: (defn sdescriptive-name [] <many lines>) (def my-atom (atom (descriptive-name)))
Where descriptive-name would describe the data shape or purpose. This way the atom is not obscured behind many lines of code and the data-generation is factored into a testable function with a hopefully self-documenting name. On Thu, 10 Dec 2015 at 10:27 Colin Yates <colin.ya...@gmail.com> wrote: > I know it is dangerous to make sweeping statements, but any solution to “a > lot of code obscures meaning therefore do X” is often solving the wrong > thing - the real problem is "a lot of code that obscures meaning” :-). > > I hope that doesn’t come across as condescending as I fear... > > > On 10 Dec 2015, at 06:02, Mars0i <marsh...@logical.net> wrote: > > Another use case, fwiw: > > (def my-atom > (let [... > <many lines> > ...] > (atom ...))) > > A special naming convention for (e.g.) atoms makes it clear that what's > below the many lines of let bindings (and maybe comment lines, too) is > going to produce an atom; you don't have to read down and find the one line > that contains '(atom'. > > -- > 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. > > > -- > 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. > -- 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.