Re: StackOverflowError

2013-11-09 Thread Jim - FooBar();
Hi Ru, Think of it this way...In Java you can't declare something as public from within a method. Ok, in Java this would break the object's contract but even if you look at languages like python, you still don't define global variables from within functions. I have seen python code where fun

Re: StackOverflowError

2013-11-09 Thread ru
Yes, it is. I reworked my code and removed where it is possible global assignments through *def*, particulary, from the function *retract-fact*. But, I can not do without global mutations altogether, so I have to use atom, ref, agent etc., as you suggested. But, do mutation of these structures

Re: gemacl: Scientific computing application written in Clojure

2013-11-09 Thread Jose M. Perez Sanchez
Hi Andy: Thanks a lot for your reply. I'll do more careful testing in the very near future and there is surely a lot to optimize in my code. I must say I did expect computing speed reduction coming from an already optimized codebase with the perfomance critical parts written in C, and there is

monads not working in Clojure 1.4.0

2013-11-09 Thread Gary Zhao
Hello I saw the following error when using monads in Clojure 1.4.0, however it worked fine in Clojure 1.5.1. Isn't monads compatible with 1.4.0? [org.clojure/clojure "1.4.0"] [org.clojure/algo.monads "0.1.4"] NoSuchMethodError clojure.lang.RT.mapUniqueKeys([Ljava/lang/Object;)Lclojure/lang/I

Re: monads not working in Clojure 1.4.0

2013-11-09 Thread Michael Klishin
2013/11/9 Gary Zhao > NoSuchMethodError > clojure.lang.RT.mapUniqueKeys([Ljava/lang/Object;)Lclojure/lang/IPersistentMap; > clojure.algo.monads/loading--4910--auto-- (monads.clj:11) > It means you have some code compiled against 1.5.1 in monads, one of the other libraries or your own code. Run l

Re: Does Pedestal have a future in the long run

2013-11-09 Thread Ryan Neufeld
Stuart Halloway is doing a presentation and we’ll be dumping a lot more new stuff into the repository. I made a mistake in saying we had an announcement, it’s more just that we’ll be talking more publicly about what we’re working on following next week. -Ryan  On November 8, 2013 at 5:39:34 P

Python doctest in clojure?

2013-11-09 Thread dechouxb
Hello, While reading about tests in Python, I found the doctest module : http://docs.python.org/3/library/doctest.html#module-doctest. Essentially, the idea is that the documentation of the function is parsed/evaluated. And if something looks like an example it is run and verified. The neat co

Re: gemacl: Scientific computing application written in Clojure

2013-11-09 Thread Andy Fingerhut
Jose: On re-reading your original post, I noticed one statement you made that may be of interest: "The resulting vector for each particle is then added (conj) to a global vector for latter storage." Do you mean that there is a single global vector that is conj'd onto by all N threads? Is this ve

Reactive Programming in Clojure

2013-11-09 Thread Marco Manzi
Hi all, I'm a young clojure developer. I work as Java developer, but I've falled in love with this fantastic language and I would like to help in some way. Actually I'm following Principles of Reactive Programming on Coursera. It is all written in Scala

Principles of reactive programming in Clojure

2013-11-09 Thread Marco Manzi
Hi, I'm a young clojure developer from Italy. I have made a blog that help people that want to follow https://www.coursera.org/course/reactive not writing code in Scala but in Clojure. If you are interested go to http://reactiveclojure.blogspot.it. I appreciate any hint :) -- -- You received t

Re: gemacl: Scientific computing application written in Clojure

2013-11-09 Thread Jose M. Perez Sanchez
Hi Andy: Yes, this breaks embarrassing parallelism indeed. When the calculations are done for real this isn't a problem though, because these conj operations to the global list would happen sporadically (in average once every couple of seconds or so) so the probability of a thread waiting for

Re: Python doctest in clojure?

2013-11-09 Thread James Reeves
The standard clojure.test namespace included in Clojure has this functionality (or something very similar) by default. You can attach tests as metadata to a function, either like: (defn foo {:test (fn [] (is (= (foo 1) 2)))} [x] (+ x 1)) Or like: (with-test (defn