Seeing that some contrib libs have been promoted into the main clojure project, I'd like to suggest that the same be done for clojure.contrib.def (or, the majority of it). We use it nearly everywhere, and I suspect many others do as well.
As a slight caveat, I'm not sure that the defalias, defhinted, or name- with-attributes members in def are central enough and/or used enough to warrant promotion. It seems reasonable that they'd be "left behind" in c.c.def, with the other forms promoted -- either into core.clj or into a clojure.def namespace.
> Seeing that some contrib libs have been promoted into the main clojure > project, I'd like to suggest that the same be done for > clojure.contrib.def (or, the majority of it). We use it nearly > everywhere, and I suspect many others do as well.
> As a slight caveat, I'm not sure that the defalias, defhinted, or > name- > with-attributes members in def are central enough and/or used enough > to warrant promotion. It seems reasonable that they'd be "left > behind" in c.c.def, with the other forms promoted -- either into > core.clj or into a clojure.def namespace.
As long as the documentation doesn't disappear between the time the
library is removed from contrib and the appropriate version (1.1, 1.2)
of Clojure is released.
> On Aug 14, 2009, at 10:10 AM, Chas Emerick wrote:
> > Seeing that some contrib libs have been promoted into the main clojure
> > project, I'd like to suggest that the same be done for
> > clojure.contrib.def (or, the majority of it). We use it nearly
> > everywhere, and I suspect many others do as well.
> > As a slight caveat, I'm not sure that the defalias, defhinted, or
> > name-
> > with-attributes members in def are central enough and/or used enough
> > to warrant promotion. It seems reasonable that they'd be "left
> > behind" in c.c.def, with the other forms promoted -- either into
> > core.clj or into a clojure.def namespace.
Though, I think that a "def-" would be redundant if the defvar macros
are promoted. Perhaps it would be sensible to keep def as a the
underlying special form and just move in defvar, defvar- and
defmacro-.
I'm not sure whether defonce is useful enough that it should be moved
to core, so I'll abstain.
The larger macros (eg. defnk) should definitely remain in contrib.
Docs for cutting edge Clojure are on the way. Rich said he was going
to think about the approach he wanted to take and we'll get it up and
running when he gets back from vacation.
Hang tight,
Tom
On Aug 14, 10:21 am, Sean Devlin <francoisdev...@gmail.com> wrote:
> As long as the documentation doesn't disappear between the time the
> library is removed from contrib and the appropriate version (1.1, 1.2)
> of Clojure is released.
> On Aug 14, 12:52 pm, Daniel Lyons <fus...@storytotell.org> wrote:
> > On Aug 14, 2009, at 10:10 AM, Chas Emerick wrote:
> > > Seeing that some contrib libs have been promoted into the main clojure
> > > project, I'd like to suggest that the same be done for
> > > clojure.contrib.def (or, the majority of it). We use it nearly
> > > everywhere, and I suspect many others do as well.
> > > As a slight caveat, I'm not sure that the defalias, defhinted, or
> > > name-
> > > with-attributes members in def are central enough and/or used enough
> > > to warrant promotion. It seems reasonable that they'd be "left
> > > behind" in c.c.def, with the other forms promoted -- either into
> > > core.clj or into a clojure.def namespace.
> > > Thoughts?
> > I myself am rather fond of defvar. I'm for it.
If defvar was
[doc-string? name init?]
It would obviate defunbound
(defvar "A set of current TCP connections"
connections #{})
And the backward compatible form could still be supported if necessary
[name init? doc-string?]