Blargh!!! I've committed a good old-fashioned PEBCAK.
I should have been more specific. I executed this in SLIME/OSX and
enclojure/XP. The problem was that the output wasn't going to *out*
like I'd expect.
I tried a different example, and everything is cool.
user=>(def my-agent (agent 0))
us
On Thu, Nov 12, 2009 at 07:50:31AM -0800, Sean Devlin wrote:
>(defn daemon
> "Creates a new daemon thread and sets runnable to f"
> [f]
> (let [t (Thread. f)]
>(do
> (.setDaemon t true)
> (.start t)
> t)))
>
>And I tried calling
>
>user=>(daemon #(println "foo"))
>
>I get the
Hi all,
I'm trying to get a periodic daemon thread working. I've read some of
the stuff here:
http://groups.google.com/group/clojure/browse_thread/thread/4bc06d413fda157f/e953bb0c9286c5a7
With no luck. My code looks like this
(defn daemon
"Creates a new daemon thread and sets runnable to f"