2011/9/11 Kevin Downey
> I hate to see agents used this way. If people want a thread pool they
> should either use the ones provided by clojure, or create their own.
>
That's right, the "agents" part of my answer is more a hack.
But the more interesting point I wanted to bring to the table for
what you were suggesting, if I understand correctly, is
re-implementing futures using agents instead of a thread pool.
send an action off to an agent to be run, return a promise, the action
delivers to the promise when the action completes. derefing the
promise blocks until the action is run to co
Hi,
now that I've stepped back a little bit and acknowledged my ignorance (while
working on it : currently reading "Java concurrency in practice" :-) ), I
can see why I've been so prompt to suggest that (while I can remember having
said to others that using agents without caring about their state
There should be an initiative to built own ide, look at Java history,
it become popular when good ide with debugers, docs, highlighting and
refactoring appeared. Clojure should have such ide, my vote right now
is for clooj, since this is the only one ide written in supported
language itself. Just c
Imho, using agents(or fixed size thread pool) in my case could be
worst than using an unbounded thread pool. There's a risk to have all
agents blocked waiting for each other.
The library "die-geister" seems to perfectly fit my needs. Great!
Still I would be grateful to hear a solution using only th
Hi Curran,
I made this video for hacking Overtone with Emacs:
http://vimeo.com/25190186
However, Overtone can just be viewed as an example project - it's really just a
description of how to get a working Clojure/Emacs setup.
Sam
---
http://sam.aaron.name
On 10 Sep 2011, at 18:29, Curran wrot
Or
(load-string "(+ 1 (+ 2 4))")
Jonathan
On Fri, Sep 9, 2011 at 5:14 PM, Chouser wrote:
> On Thu, Sep 8, 2011 at 5:16 PM, Tassilo Horn
> wrote:
> > Hi all,
> >
> > I've just read Alan Malloy's excellent clojure persistence article at
> >
> >
> http://amalloy.hubpages.com/hub/Dont-use-XML-JSON
Sort of.
http://georgejahad.com/clojure/cdt.html
Jonathan
On Sat, Sep 10, 2011 at 5:36 PM, Dennis Haupt wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
>
> hi there,
>
> what's the currently best way to debug a clojure program?
> ideally, i want to see all vars, symbols, functions et
I've had no problems with functions containing ->
Jonathan
On Fri, Sep 9, 2011 at 10:47 AM, Christina Conway
wrote:
> A function name contains the characters ->
> e.g. foo->fn
> The function causes an exception.
> However the exception is not reported on the function but on another
> function
Hi George,
> Once again, I make a globally referenced, infinitely long stream. But
> now I use "lazy-seq"
> instead of "cycle":
>
>user=> (def ev-stream (lazy-seq (cons true (cons false ev-
> stream
>#'user/ev-stream
>user=> (defn ev? [n] (nth ev-stream n))
>#'user/ev?
>
> The foo->fn function is compiled to a .class file as:
> foo__GT_fn.class
> The foo>fn function is compiled to a .class file as:
> foo_GT_fn.class
> The foo-fn function is compiled to a .class file as:
> foo_fn.class
>
> Has anybody else encountered this with function names containing ->.
> Is thi
As an avid Emacs user - don't bother. If you just want a no hassle
environment that supports Clojure development use Clooj. Steps -
1) Download
2) Double-click
https://github.com/arthuredelstein/clooj
David
On Sat, Sep 10, 2011 at 1:29 PM, Curran wrote:
> Greetings,
>
> I would greatly apprec
+1
--
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
cl
I don't know why an error message doesn't show, but the swank clojure readme
explains a fallback method (lein swank + M-x slime-connect) that you could
try.
-Phil
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to cl
I use Emacs for virtually everything, but have found that Emacs
+Clojure is less than idea when working with multiple threads (like
hosting and running a Jetty server). I believe this is mostly related
to how Java and Emacs+Slime handles input/output redirection. I went
crazy trying to figure out w
On 11 Sep 2011, at 16:37, kjeldahl wrote:
> I use Emacs for virtually everything, but have found that Emacs
> +Clojure is less than idea when working with multiple threads (like
> hosting and running a Jetty server). I believe this is mostly related
> to how Java and Emacs+Slime handles input/out
Yes, I had better success with cake (when I used it). But with the
lein setup, I believe most of it goes into a swank buffer of some
sort, which also contain a lot of other (non-related) output, and
exactly where in that buffer it also ends up seems a bit
undeterministic. But again, just my experie
Couldn't match expected type `(t, t1)'
against inferred type `(t2, t3, t4)'
In the expression: (8, 11, 5)
In the expression: [(1, 2), (8, 11, 5), (4, 5)]
In the definition of `it': it = [(1, 2), (8, 11, 5), (4, 5)]
This was excerpt from Haskell exception, will Clojure have ever
somethin
On Mon, Sep 5, 2011 at 1:26 PM, Stefan Kamphausen
wrote:
> could you please elaborate a bit on the swank-clojure issue? Alternatively
> just point me to the threads that I should have read more closely.
Now that Leiningen has user-level plugins, there's no need to put
swank in project.clj since
On Sun, Sep 11, 2011 at 1:29 AM, Laurent PETIT wrote:
> now that I've stepped back a little bit and acknowledged my ignorance (while
> working on it : currently reading "Java concurrency in practice" :-) )
Kevin pulled me up on this too (in IRC) and pointed me at the Java
solution. As it happened
On Sun, Sep 11, 2011 at 9:09 AM, kjeldahl
wrote:
> with the lein setup, I believe most of it goes into a swank buffer of some
> sort, which also contain a lot of other (non-related) output, and
> exactly where in that buffer it also ends up seems a bit
> undeterministic.
I think it's consistent.
Have you looked at the *swank* buffer? Maybe your's is looking
differently than mine, but there's lots of stuff that I did not but
there, and which I would not have there.
My issues with this is related to running servers and catching debug
output from it while it is running (yeah, I really should
On 11 Sep 2011, at 22:42, kjeldahl wrote:
>
> I'm no expert, but if I had to choose between getting all output in a
> file, or some output in the repl buffer and some in *swank*, I would
> prefer the former (which is what I believe cake actually does).
Used from within Emacs, cake places all out
On Sun, Sep 11, 2011 at 2:42 PM, kjeldahl
wrote:
> Have you looked at the *swank* buffer? Maybe your's is looking
> differently than mine, but there's lots of stuff that I did not but
> there, and which I would not have there.
Everything in there is output from lein jack-in. Much of it is elisp,
On Sun, Sep 11, 2011 at 8:28 AM, Stuart Halloway
wrote:
> cycle actually calls lazy-seq. A quick way to check such things at the REPL
> is with source:
> user=> (source cycle)
> (defn cycle
> "Returns a lazy (infinite!) sequence of repetitions of the items in coll."
> {:added "1.0"
> :stat
On Sat, Sep 10, 2011 at 10:29, Curran wrote:
> I would greatly appreciate any guidance on where to find a working and
> complete set of instructions for how to set up Emacs with swank-
> clojure. I am in Ubuntu.
>
> I have followed exactly every step of the instructions on this page
> http://dev.
Hi Curran,
I'm in the process of learning Clojure and emacs as well and have run
into a bit of difficulty as well, though I have a slightly different
problem. I grabbed the 23.3 version of emacs from their ftp site and
did NOT use the emacs starter kit. I discovered that the version of
package.e
Hello all,
I’m sending this email to several mailing lists so my apologies if you
see this twice.
Functional Programming eXchange is a developer conference that focuses
on functional programming. The 2012 edition will take place on Friday
March 16th March 2012, at the Skills Matter eXchange, in L
Cake's global project allows for dev deps to be set for all projects, so this
applies to cake as well.
--
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
Hi, Stu,
Loving your book!
I posted a reply earlier, through a different interface, which went
to "moderators". Sorry for the clumsiness, but I'm not familiar with
the mechanics of newsgroups.
On Sep 11, 7:28 am, Stuart Halloway wrote:
> The consing version of ev-stream is self-referentia
Greetings,
Wow, thank you all so much for the insightful responses to my inquiry!
I really appreciate the supportive community.
I developed a small web app in Clooj over the weekend and was very
impressed by it! A very cool idea to write the IDE for the language,
in the language, with the essenti
Clojure's concurrency primitives are built on the functionality
provided by java.util.concurrent and I think solutions for
asynchronous composition should also be built on java.util.concurrent.
Agents are identities over a series of results from asynchronous
function application. Nothing about comp
Hi, when i first came to clojure world i've started with tutorial for
java programers, now i'm reading about haskell and for almost every
new feature I know that my favorite language clojure already has that,
but i'm not fully sure which feature it is. For example comprehensions
are implemented by
I believe the bug can be blamed on "nth".
Using "nth", I make a function which should be identity on natural
numbers:
Clojure 1.2.1
user=> (defn ident [n] (nth (iterate inc 0) n))
#'user/ident
And it works, for reasonable size numbers:
user=> (ident 12345)
12345
user=> (ident 7654321)
7654321
Integer overflow.
user> (mod 9876543210 (bigint (Math/pow 2 32)))
1286608618
On Sep 11, 9:44 pm, George Kangas wrote:
> I believe the bug can be blamed on "nth".
>
> Using "nth", I make a function which should be identity on natural
> numbers:
>
> Clojure 1.2.1
> user=> (defn ident [n] (nth (ite
G'day.
The API documentation for clojure doesn't specify if the sort method
is stable, unstable, or "implementation defined".
Java defines sort to be stable, but Clojure also has two other
targets, and I can't tell if I am safe making the assumption that the
stable behaviour will carry over to th
>
> Also, if I can't get Emacs going, would anyone suggest an alternative
> development tool? (I know there are lots, but I don't know which to
> try first).
>
> I use IntelliJ IDEA with La Clojure and Leiningen plugin. I usually create
a skeleton project with leiningen on the command line, t
My recollection of how cake did it was probably wrong.
As for how I would like to have it, I would like to have all output
from all threads appear in the emacs repl buffer, similar to how it
behaves in "console" mode, and that is what I haven't figured out how
to do or found any workaround for, ex
38 matches
Mail list logo