Hi,
On Oct 6, 1:23 am, MarkSwanson wrote:
> I wonder if this concept will be thought of as a source of problems in
> the future. Or, maybe this is just one of those fundamental Clojure
> concepts you just have to learn and once you do you find you don't get
> bit by it.
This is a side-effect o
Hi,
Am 06.10.2009 um 00:55 schrieb Mark Tomko:
To be explicit, the doall needs to be before the call to recur (that
is, it affects the map). Is that right?
Yes. It must look like (recur (doall (map ...))).
Sincerely
Meikel
smime.p7s
Description: S/MIME cryptographic signature
I do have a novel idea to work around this but I've yet to put my theory to
code and publish it.
The problems I had when loading clojure based bundles into OSGi was that
after unloading, the classes remained loaded by the bundle providing RT.
The basic idea was to add a bundle listener to the OSG
I develop Clojuratica.
Kyle---I had no idea it works with Player. That's cool and interesting.
Patrick---If you're doing straight-up numerical matrix algebra and require
the greatest possible performance you'll probably do best with Parallel
Colt. There's no time spent on data-type conversion and
At first glance this is surprising to me and I'm sure I would be
tripped up by this at least a few times before I finally learned my
lesson.
On Mon, Oct 5, 2009 at 5:23 PM, MarkSwanson wrote:
>
> To expand on Meikel's nice explanation:
> (to see if I understand correctly)
>
> 1. (defn baz ...)
>
Thanks for the replies. Those are exactly what I need!
-Patrick
--~--~-~--~~~---~--~~
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
There is this project going on:
http://wiki.github.com/romanroe/ogee
--~--~-~--~~~---~--~~
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
Hi,
I think http://sites.google.com/site/piotrwendykier/software/
parallelcolt">Parallel Colt has picked up where Colt left off.
It's a very full featured library and forms the basis of the Clojure
stats package http://incanter.org/>Incanter.
Personally, I've used the sparse vector classes in Pa
To expand on Meikel's nice explanation:
(to see if I understand correctly)
1. (defn baz ...)
2. (binding [foo bar] (baz [1 2 3])) - dynamically binds foo and
creates a lazy-seq response to the baz fn. Because map is lazy the [1
2 3] sequence is actually not read by anything within the binding
d
To be explicit, the doall needs to be before the call to recur (that
is, it affects the map). Is that right?
On Oct 5, 1:31 am, Meikel Brandmeyer wrote:
> Hi,
>
> On Oct 5, 9:50 am, Volkan YAZICI wrote:
>
> > > (defn leak []
> > > (loop [v [0 0]]
> > > (recur (map + v [1 1]
>
> > >
clojuratica works with the free mathematica player. I don't think
there are any licensing issues, but I could be wrong. I need to do
more benchmarking, but the performance is pretty good so far.
--~--~-~--~~~---~--~~
You received this message because you are subsc
Hi,
Am 05.10.2009 um 20:37 schrieb Daniel Janus:
(defn baz [s] (map (fn [_] (foo)) s))
user=> (binding [foo bar] (baz [1 2 3]))
(42 42 42) ;; while I would expect (44 44 44).
Am I missing something here?
You are missing lazyness. The (42 42 42) is printed at the Repl. That
realises the seq
Dear Clojurians,
Consider the following three simple functions:
(defn foo [] 42)
(defn bar [] 44)
(defn baz [s] (map (fn [_] (foo)) s))
Now let's rebind foo to bar:
user=> (binding [foo bar] (foo))
44 ;; Just as I expected.
user=> (binding [foo bar] (baz [1 2 3]))
(42 42 42) ;; while I would e
Hi,
I need to do some high performance numerical data crunching and was
wondering what libraries are popular. I have looked into Colt and
JAMA, but neither have had much development recently (Colt hasn't had
a release since 2004, and JAMA since 2005), and I'm not sure if
they're still alive. Cloju
On Mon, Oct 5, 2009 at 11:51 AM, MarkSwanson wrote:
> On Oct 5, 2:45 am, ngocdaothanh wrote:
> > I think it is not "spawn about 20K agents / second", it is 20K message
> > passings / second. The number is about that of Erlang.
>
> As Clojure uses a thread pool for agents I agree 'spawn' was the w
On Mon, Oct 5, 2009 at 2:38 PM, Meikel Brandmeyer wrote:
> Hi,
>
> Am 05.10.2009 um 19:29 schrieb cody koeninger:
>
> Here we have the smell! You cannot define functions with a function.
>>> You have to use a macro!
>>>
>>
>> I am not clear on what you mean by this. From a user's point of view,
It's possible to modify Clojure to run under OSGi (search the list
archives) but fundamentally they don't fit. OSGi assumes that it has
sole control of class loading. But Clojure needs its own
classloader. To make them cooperate, I think you would need to
integrate Clojure with the OSGi contain
Hi,
Am 05.10.2009 um 19:29 schrieb cody koeninger:
Here we have the smell! You cannot define functions with a function.
You have to use a macro!
I am not clear on what you mean by this. From a user's point of view,
what is the difference between defining a function, and interning a
var with
> You're right, it was a memory leak, although it took me hours to find.
> Clojure's lazy lists were responsible for the leak; I wasn't honestly
> expecting this innocent looking code to be so insidious
$0.02 another instance of this that makes me think laziness needs to
be explicit in the sy
On Oct 4, 1:31 am, Meikel Brandmeyer wrote:
> Here we have the smell! You cannot define functions with a function.
> You have to use a macro!
I am not clear on what you mean by this. From a user's point of view,
what is the difference between defining a function, and interning a
var with a fn
On Sat, Oct 3, 2009 at 7:23 AM, pmf wrote:
>
> And String is final, making deriving from it impossible.
>
> One way (most probably not the best way) would be to wrap it in a Var
> and attach the metadata to the Var, i.e.
>
> (def #^{:blah :foo} my-string "some string")
>
> Note that to access th
On Sun, Oct 4, 2009 at 4:41 PM, samppi wrote:
>
> I want to do this:
>
> (defn a ...)
> (cache a) ; or (cache #'a) or (cache 'a); it doesn't matter to me
>
> ...instead of this:
>
> (def a (memoize (fn ...)))
>
> That way, it separates the concern of what a does from the
> optimization I'm doi
On Oct 5, 2:45 am, ngocdaothanh wrote:
> I think it is not "spawn about 20K agents / second", it is 20K message
> passings / second. The number is about that of Erlang.
As Clojure uses a thread pool for agents I agree 'spawn' was the wrong
word. Thanks for the correction.
--~--~-~--~---
Hi,
I am an OSGi enthusiast. Lately I have been looking at scheme and
clojure. I can't help but wonder if there are any genuine benefits
clojure can get from being a full OSGi citizen. It seems to me that
OSGi is to statically compiled Java what the REPL is for Clojure.
Except the REPL is more pow
>
>
> (dosync (dorun (for [key ks] (alter file-seq-cache dissoc key
>>
>
> You might want to write (dorun (for ...)) as (doseq ...). Since you don't
> use the resulting sequence using for to generate sequence and then using to
> dorun to force it and immediately throw it away is very ugly.
Hi,
On Oct 5, 11:02 am, Tim Sally wrote:
> At the moment I'm only interested in the documentation lookup
> functions, so I did not start the nailgun server. I had assumed that
> the nailgun server was only necessary for evaluating code, but I
> didn't read the README carefully enough. S
Hi,
At the moment I'm only interested in the documentation lookup
functions, so I did not start the nailgun server. I had assumed that
the nailgun server was only necessary for evaluating code, but I
didn't read the README carefully enough. Starting the server was the
missing step.
Tha
Hi,
On Oct 5, 9:50 am, Volkan YAZICI wrote:
> > (defn leak []
> > (loop [v [0 0]]
> > (recur (map + v [1 1]
>
> > Adding a doall call fixed the leak.
>
> Could you please provide a more concrete (if possible working) example?
> I'm trying to figure out the actual reason of the problem
Hi,
On Oct 5, 12:14 am, Tim Sally wrote:
> I'm having a problem getting VimClojure working. I've tried with both
> the development and stable versions. For this minimal example, I use
> the stable version and ivy to resolve the dependencies. However I
> have tried installing with a correct l
On Sun, Oct 4, 2009 at 4:41 PM, samppi wrote:
>
> I want to do this:
>
> (defn a ...)
> (cache a) ; or (cache #'a) or (cache 'a); it doesn't matter to me
>
> ...instead of this:
>
> (def a (memoize (fn ...)))
>
> That way, it separates the concern of what a does from the
> optimization I'm doi
Hey all,
I'm having a problem getting VimClojure working. I've tried with both
the development and stable versions. For this minimal example, I use
the stable version and ivy to resolve the dependencies. However I
have tried installing with a correct local.properties file as well
with no luck.
On Sun, 4 Oct 2009, Elliott Slaughter writes:
> You're right, it was a memory leak, although it took me hours to find.
> Clojure's lazy lists were responsible for the leak; I wasn't honestly
> expecting this innocent looking code to be so insidious
>
> (defn leak []
> (loop [v [0 0]]
>
32 matches
Mail list logo