Re: Question about sets

2012-09-08 Thread Andy Fingerhut
The new ticket CLJ-1065 has a patch that I think implements the desired behavior on the dev wiki page. i.e. set/map literals with duplicates are invalid (status quo) All constructor functions for sets and maps allow duplicates, and for maps, always take the value associated with the last

Re: redefining multimethods at the repl

2012-09-08 Thread Denis Labaye
On Wed, Sep 5, 2012 at 12:31 AM, Brian Marick mar...@exampler.com wrote: I'm trying to write exercises for multimethods. Book readers will be working at the repl. Multimethods are stateful in a bad way, as shown below. Is there some sort of trick to using multimethods at the repl, or should I

Re: ANN Ritz 0.4.1

2012-09-08 Thread Denis Labaye
On Fri, Sep 7, 2012 at 9:11 PM, Hugo Duncan h...@hugoduncan.org wrote: Ritz is a collection of repl servers, middleware and repl utility functions, supporting nREPL and swank/slime. The repl utilities can be used from any repl. Does ritz/swank replace lein-swank? Thanks, Denis The

Re: Literate Programming in org-babel (ob-clojure.el) is broken under nrepl.el

2012-09-08 Thread Denis Labaye
On Thu, Sep 6, 2012 at 6:42 PM, lambdatronic gwjoh...@uvm.edu wrote: For those people (like myself) who do a lot of Literate Programming in Emacs using Clojure and org-babel, migrating to nrepl and nrepl.el is somewhat non-trivial. This is because the existing Clojure support in org-babel

Re: [ANN] clojure-encog has a new name and repo

2012-09-08 Thread Denis Labaye
On Tue, Sep 4, 2012 at 9:05 PM, Jim - FooBar(); jimpil1...@gmail.comwrote: Hi all, just wanted to let you know that I renamed 'clojure-encog' to *enclog* ...release 0.5.0 does not add anything but several 'library coding standards' that i was previously not aware of, have been addressed...

Re: Does moustache work with latest ring and clojure ?

2012-09-08 Thread Murtaza Husain
Herwig/Marko, Below is the code - (def my-app (app wrap-stacktrace (wrap-file resources/public/) [] Hello World [/] Hello World Second [page] (- (chrome page) response constantly) [] (- Nothing was found response

Re: [ANN] clojure-encog has a new name and repo

2012-09-08 Thread Jim - FooBar();
Hi Denis, you cannot bring 2 vars named 'network' in the same namespace...It is partly my fault cos since I changed 'make-network' to 'network' I should have changed the examples as well...try again but instead of 'network' define your neural-net as 'net' or something cos there is alaredy a

Re: ANN Ritz 0.4.1

2012-09-08 Thread Hugo Duncan
Denis Labaye denis.lab...@gmail.com writes: On Fri, Sep 7, 2012 at 9:11 PM, Hugo Duncan h...@hugoduncan.org wrote: Ritz is a collection of repl servers, middleware and repl utility functions, supporting nREPL and swank/slime. The repl utilities can be used from any repl. Does ritz/swank

Re: Question about sets

2012-09-08 Thread Rich Hickey
Thanks! I'm still interested in patch for recommendation #3: Restore the fastest path possible for those cases where the keys are compile-time detectable unique constants I'd like to see all three recommendations go into a release as a set. On Sep 8, 2012, at 2:22 AM, Andy Fingerhut wrote:

Re: edn

2012-09-08 Thread Steven E. Harris
Michael Fogus mefo...@gmail.com writes: Data formats do not exist in a vacuum. They are parsed by languages. Some may have a fine-grained distinction between lists, arrays/vectors and sets and some may not. The concern I have is for someone wanting to define a format atop EDN -- or, to put

Re: [ANN] clojure-encog has a new name and repo

2012-09-08 Thread Jim - FooBar();
Hi Denis, as promised, I pushed enclog 0.5.2-SNAPSHOT to clojars 5 minutes ago and updated the demo examples on github to show the new code style. tested all the examples and everything works just fine...if you find anything unusual feel free to poke me :-) aaa btw 0.5.2 has nice

Re: [ANN] clojure-encog has a new name and repo

2012-09-08 Thread Denis Labaye
On Sat, Sep 8, 2012 at 2:00 PM, Jim - FooBar(); jimpil1...@gmail.comwrote: Hi Denis, you cannot bring 2 vars named 'network' in the same namespace... I choose another name for the network, but even with that I got the clojure.lang.MultiFn cannot be cast to

Re: [ANN] clojure-encog has a new name and repo

2012-09-08 Thread Jim - FooBar();
On 08/09/12 16:56, Denis Labaye wrote: Anyway, it works fine with the 0.5.2-SNAPSHOT (I've got network traing logs), but how do I use the network I just trained ? In your example I would like to give it a new input, and see if it learned correctly his xor lesson :) basically, you need to

Re: edn

2012-09-08 Thread Armando Blancas
I'd say on the basis of convenience, since we get to serialize and deserialize for free (o with customizations), and for most cases the author on both ends is likely to be the same person or team. For other languages, producers don't work any harder either way, and consumers are free to

Re: Bug in CLJS `symbol` with quoted symbol

2012-09-08 Thread David Nolen
On Sat, Sep 8, 2012 at 1:50 AM, Shantanu Kumar kumar.shant...@gmail.com wrote: Hello, I found this bug related to `symbol` and quoted symbols in CLJS. Explained below. In Clojure: user= (= 'a (symbol 'a)) true In CLJS: ClojureScript:cljs.user (= 'a (symbol 'a)) false Unless this is

Re: Bug in CLJS `symbol` with quoted symbol

2012-09-08 Thread David Nolen
On Sat, Sep 8, 2012 at 1:50 AM, Shantanu Kumar kumar.shant...@gmail.com wrote: In CLJS: ClojureScript:cljs.user (= 'a (symbol 'a)) false Shantanu Fixed in master. -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email

Re: Bug in CLJS `symbol` with quoted symbol

2012-09-08 Thread Shantanu Kumar
On Saturday, 8 September 2012 23:36:49 UTC+5:30, David Nolen wrote: On Sat, Sep 8, 2012 at 1:50 AM, Shantanu Kumar kumar.s...@gmail.comjavascript: wrote: In CLJS: ClojureScript:cljs.user (= 'a (symbol 'a)) false Shantanu Fixed in master. Thanks! Shantanu -- You

Re: edn

2012-09-08 Thread Ben Smith-Mannschott
On Fri, Sep 7, 2012 at 3:01 AM, Rich Hickey richhic...@gmail.com wrote: I've started to document a subset of Clojure's data format in an effort to get it more widely used as a data exchange format, e.g. as an alternative to JSON. Please have a look: https://github.com/richhickey/edn If

Re: edn

2012-09-08 Thread Steven E. Harris
Ben Smith-Mannschott bsmith.o...@gmail.com writes: I follow forbidding -4bar since that means potentially unbounded look-ahead to distinguish numbers from non-numbers. Presumably forbidding .4bar is for the same reason, though .01 doesn't appear to be a valid numeric literal. (Numeric

Re: edn

2012-09-08 Thread Steven E. Harris
Armando Blancas abm221...@gmail.com writes: I'd say on the basis of convenience, since we get to serialize and deserialize for free (o with customizations), and for most cases the author on both ends is likely to be the same person or team. I find that to be a specious defense. If we expect

Re: algo.monad state-m fetch-val bug and efficiency issue

2012-09-08 Thread Stephen Compall
On Sat, 2012-09-08 at 07:39 +0200, Phlex wrote: I was unable to contact a maintainer of this library on irc I suggest using http://dev.clojure.org/jira/browse/ALGOM to report algo.monads bugs. https://gist.github.com/3667614 -(key s))) ;; only works for keyword keys +(key s))) ;;

Can't start Rhino repl for ClojureScript

2012-09-08 Thread Alan Shaw
Hi, Any help wd be appreciated; this is what happened (environment is Cygwin on win7): $ lein2 trampoline cljsbuild repl-rhino Running Rhino-based ClojureScript REPL. (do (require (quote cljsbuild.repl.rhino)) (do (clojure.core/ns leiningen.core.injected) (defn- compose-hooks [f1 f2] (fn [ args]

Re: algo.monad state-m fetch-val bug and efficiency issue

2012-09-08 Thread Phlex
You sir are nitpicking on me ! On 9/09/2012 02:05, Stephen Compall wrote: https://gist.github.com/3667614 -(key s))) ;; only works for keyword keys +(key s))) ;; works for arbitrary functions You of course are right, the key parameter could be a function and this might be useful in

Re: algo.monad state-m fetch-val bug and efficiency issue

2012-09-08 Thread Stephen Compall
On Sun, 2012-09-09 at 03:33 +0200, Phlex wrote: the docstring explicitly says that the state is a map and that the function returns the value corresponding to this key. This does break for a string or integer key. There is no way around it, this is a bug. Sure, but a documentation bug, or a