Re: core.match and AOT

2012-10-16 Thread Paudi Moriarty
See http://dev.clojure.org/jira/browse/MATCH-63 for details.

Paudi

On 15 October 2012 23:21, David Nolen dnolen.li...@gmail.com wrote:

 On Mon, Oct 15, 2012 at 5:09 PM, Paudi Moriarty 
 pmoria...@annadaletech.com wrote:

 It's broken since alpha10, alpha9 works fine.

 Paudi


 That's useful to know, thanks :) I suspect it may have something to do
 with the predicate stuff I added.

 David

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: How to represent trees for use with zippers

2012-10-16 Thread mwillson
Dave,

Your first attempt looks OK to me.

(require '(clojure [zip :as z]))

(def zipper (z/vector-zip [:A [:B [:D :E]] [:C [:F :G]]]))

(defn pre-order [loc]
  (when-not (z/end? loc)
(when-not (z/branch? loc)
  (println (z/node loc)))
(recur (z/next loc

user= (pre-order zipper)
:A
:B
:D
:E
:C
:F
:G
nil
user= 

What made you think it didn't work?

-mark

On Monday, October 15, 2012 9:20:14 PM UTC+1, Dave Kincaid wrote:

 I stumbled across the clojure.zip library today which looks extremely 
 useful for working with trees. The only problem is I can't figure out how 
 to represent a tree as a vector so that the zipper will have the correct 
 structure. For example say I want to work with this tree:


 https://lh5.googleusercontent.com/-mq1roiqfqw4/UHxvMDQUIfI/A_o/mNA9pAkOEIs/s1600/tree.png
 my first intuition was a vector like this [:A [:B [:D :E]] [:C [:F :G]]] but 
 that didn't work. Then I thought of something like this: [[:B [:D :E]] :A 
 [:C [:F :G]]]. It seems like that gets me a little bit closer since now 
 the zipper at least gets that :A has two children.

 Can anyone help me understand how to represent a tree in a Clojure vector? 
 Is there a common lispy way of doing this that everyone already knows? It 
 seems like all of the references I could find online all assume that you 
 know how to represent a tree already.

 Thanks,

 Dave


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Evaluating an anonymous function with closure

2012-10-16 Thread Jim foo.bar

On 16/10/12 03:50, Michael Gardner wrote:

On Oct 15, 2012, at 7:45 PM, Andy Fingerhut wrote:


For the case of arithmetic on compile-time constants, I believe that many C, 
Java, etc. compilers already perform the arithmetic at compile time.

Known as constant folding, yes.



so you're saying that if I write a for-loop in Java that populates an 
array with constants from 1-1 and then a 2nd loop to add them up, it 
would happen at compile-time and i would get the same timing-result?


Jim

--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Simple way to get image from url

2012-10-16 Thread Yakovlev Roman
Ok that were good examples thanks
Final variant

add to project.clj

[clj-http 0.5.6]

add ref to lib in ns

(ns myapp.app
  *(:require [clj-http.client :as client] ))*

function 

(defn write-file [url]
   (with-open [w (clojure.java.io/output-stream img.jpg )] ; output file
 (.write w (:body (client/get url {:as :byte-array}  ; here we get 
image as byte-array
   ))

Which trlanslates to ( i hope i get it right ) :
Open file in stream mode (w) and write to it byte stream (image file ) from 
url. 

On Monday, October 15, 2012 1:06:19 PM UTC+4, Yakovlev Roman wrote:

 Hi
 I am pretty new to java world so as i found there is no simple way to get 
 image file from url like : http://example.com/image.jpg.
 What i need just to get file from url and store it to db.
 So we need to use buffer, stream and stuff to get file. I found this code 
 but i guess there is a way to get things simplier.

 (defn fetch-data [url]
   (let  [con(- url java.net.URL. .openConnection)
  fields (reduce (fn [h v] 
   (assoc h (.getKey v) (into [] (.getValue v
 {} (.getHeaderFields con))
  size   (first (fields Content-Length))
  in (java.io.BufferedInputStream. (.getInputStream con))
  out(java.io.BufferedOutputStream. 
  (java.io.FileOutputStream. out.file)) ; *Here is our 
 file *
  buffer (make-array Byte/TYPE 1024)]

 ; Not sure about that loop it's just prints size to repl if we don't need 
 that we can omit that part i guess

 (loop [g (.read in buffer)
r 0]
   (if-not (= g -1)
 (do
   (println r / size) 
   (.write out buffer 0 g)
   (recur (.read in buffer) (+ r g)

 (.close in)
 (.close out)
 (.disconnect con)))

 (fetch-data http://google.com;)




-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: CDS progress report, week 1

2012-10-16 Thread Andreas Liljeqvist
Great work guys!
This is a great gift to the community.

On Mon, Oct 15, 2012 at 7:01 PM, Wes Freeman freeman@gmail.com wrote:

 I've been watching the repo. Thanks for all the effort on this, guys.

 Wes


 On Mon, Oct 15, 2012 at 12:07 PM, Michael Klishin 
 michael.s.klis...@gmail.com wrote:

 ## TL;DR

 The Clojure documentation project [1] started off quite actively. With
 several new guides and a dozen of contributors,
 the resource is already quite useful to newcomers to the language. We
 believe this is directly related
 to our straightforward contribution process.


 ## CDS Progress Report

 A week ago we announced the new Clojure Documentation Site [1] (a.k.a.
 CDS) effort. The level of activity
 in the first week exceeded our expectations and we thought it may be a
 good idea to publish periodic reports
 (every week or two) to give the Clojure community a better idea of what
 CDS shapes up to be and what it has to offer.

 So lets start. This is a report for the week ending October 14th, 2012.


 ## In a Gist

 In the first week of CDS, we have added

  * 2 new tutorials and 6 new and 2 expanded guides
  * About 4,000 lines of changes in the content directory (does not
 include CSS or toolchain-related changes)
  * 14 merged pull requests
  * 13 contributors
  * About 1,400 unique visitors
  * About 6,000 page views with average visit duration of 2 minutes and 10
 seconds

 In addition, we have ironed out first issues in the contribution process
 and set up an IRC channel (`#clojure-doc` on `irc.freenode.net`) when
 contributors coordinate their work.


 ## New Content

 New tutorials:

  * Emacs for Clojure development:
 http://clojure-doc.org/articles/tutorials/emacs.html
  * Eclipse and Counterclockwise for Clojure development:
 http://clojure-doc.org/articles/tutorials/eclipse.html


 New guides:

  * clojure.core Overview:
 http://clojure-doc.org/articles/language/core_overview.html
  * Interoperability with Java:
 http://clojure-doc.org/articles/language/interop.html
  * Namespaces: http://clojure-doc.org/articles/language/namespaces.html
  * Polymorphism: Protocols and Multimethods:
 http://clojure-doc.org/articles/language/polymorphism.html
  * Collections and Sequences:
 http://clojure-doc.org/articles/language/collections_and_sequences.html
  * Clojure Glossary:
 http://clojure-doc.org/articles/language/glossary.html

 ## Updates

 Improved guides:

  * Functions: http://clojure-doc.org/articles/language/functions.html
  * Curated Clojure Library Directory:
 http://clojure-doc.org/articles/ecosystem/libraries_directory.html


  ## Thank You, Contributors

 CDS would not be possible without the following people who make Clojure
 community a better place:

  * Gareth Jones
  * John Gabriele
  * Claudio Perez Gamayo
  * gsnewmark
  * Phil Hagelberg
  * Lee Hinman
  * Michael Klishin
  * Julson Lim
  * Jake McCrary
  * Max Penet
  * Oleksandr Petrov
  * Robert Randolph
  * Yogthos


 1. http://clojure-doc.org
 --
 MK

 http://github.com/michaelklishin
 http://twitter.com/michaelklishin

  --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


  --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Evaluating an anonymous function with closure

2012-10-16 Thread Tassilo Horn
Jim - FooBar(); jimpil1...@gmail.com writes:

 You add the numbers at compile time, and then time how long it takes
 to...do nothing to them, at runtime. You are comparing N to zero, not
 to some smaller factor of N.

 yes but this seems almost unbelievable...i mean for simple numeric
 operations this little trick could provide a tremendous speedup.

No, not really.  To add the numbers at compile-time, they need to be
known at compile-time.  That doesn't apply in almost all situations.  If
it would, you would just write 49995000 directly instead of (apply +
(range 1)).

Or in other words, your `plus` won't work with

  (let [maxno (gimme-max)]
(plus (range maxno)))

cause (eval (range max)) will complain about `maxno` being undefined.

One example that does things like constant-folding like macrology is the
unit conversion macro in Let Over Lambda that compiles to constants if
both value and unit are given literally (recursively).

Bye,
Tassilo

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Evaluating an anonymous function with closure

2012-10-16 Thread Jim foo.bar

On 16/10/12 11:49, Tassilo Horn wrote:

One example that does things like constant-folding like macrology is the
unit conversion macro in Let Over Lambda that compiles to constants if
both value and unit are given literally (recursively).


unit conversion! this is exactly what i had in mind!!! when doing unit 
conversion we have all the numbers + the formula upfront! where can I 
find this macro that you're describing? Have you got the book? Could you 
copy and paste it here please?


could the same be done in Java?

Jim

--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Evaluating an anonymous function with closure

2012-10-16 Thread Tassilo Horn
Jim foo.bar jimpil1...@gmail.com writes:

Hi Jim,

 One example that does things like constant-folding like macrology is
 the unit conversion macro in Let Over Lambda that compiles to
 constants if both value and unit are given literally (recursively).

 unit conversion! this is exactly what i had in mind!!! when doing unit
 conversion we have all the numbers + the formula upfront! where can I
 find this macro that you're describing? Have you got the book? Could
 you copy and paste it here please?

You are lucky, the early chapters are online.  See

  unit-of-time in http://letoverlambda.com/index.cl/guest/chap3.html

  defunits and defunits-chaining in
  http://letoverlambda.com/index.cl/guest/chap5.html

There's also a Clojure version floating around the web, and I think I've
seen it in some of Stu's presentations.  But I think that doesn't try to
compile to constants, e.g., it omits the defunits chaining part.

 could the same be done in Java?

I think, Java compilers do a bit of constant folding for things like

 int x = 1 + 2 * 3; // - int x = 7;

or

 final static int MAX=10;
 // ...
 int x = MAX + 1;   // - int x = 11;

Bye,
Tassilo

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Making CLJS output smaller

2012-10-16 Thread Herwig Hochleitner
2012/10/16 David Nolen dnolen.li...@gmail.com


 Yep I think there are quite a few things like this. But I don't think we
 need an optimization pass for this paticular case (and I'm not saying
 that's not a good idea - see below). Hopefully we can a direct patch for
 this issue around top level deftypes/records.


Certainly, such a simple optimization (omitting var reads in a statement
context) could live in the emitter.
The next stumbling block to a smaller clojurescript, however, is the
global-hierarchy var, which doesn't get removed by the closure compiler. To
shake that var, some closed world optimization could be utilized. I'd be
happy to work on that, but I need compilation units in order to do that.

Another use case for compilation units I can think of from the top of my
head are constant pools.

Definitely needs a Confluence page. I know several people are interested in
 this. I think it would be pretty sweet to provide common optimizations out
 of the box.


Seems like I can't edit Confluence. Could somebody elevate my privileges?

Is it OK if I create a page Compilation Units?

kind regards

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Evaluating an anonymous function with closure

2012-10-16 Thread Michael Gardner
On Oct 16, 2012, at 5:16 AM, Jim foo.bar wrote:

 so you're saying that if I write a for-loop in Java that populates an array 
 with constants from 1-1 and then a 2nd loop to add them up, it would 
 happen at compile-time and i would get the same timing-result?

Maybe, maybe not. Compilers are very smart these days, but I don't know if they 
can fold complex expressions like for-loops.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Simple way to get image from url

2012-10-16 Thread Zhitong He
another way to solve this,  from
http://users.utu.fi/machra/posts/2011-08-24-2-reddit-clojure.html

(ns myapp.app
   (:require [clojure.java.io :as io]))

 (defn copy [uri file]
 (with-open [in (io/input-stream uri)
 out (io/output-stream file)]
   (io/copy in out)))



On Tue, Oct 16, 2012 at 6:32 PM, Yakovlev Roman felix...@gmail.com wrote:
 Ok that were good examples thanks
 Final variant

 add to project.clj

 [clj-http 0.5.6]

 add ref to lib in ns

 (ns myapp.app
   (:require [clj-http.client :as client] ))

 function

 (defn write-file [url]
(with-open [w (clojure.java.io/output-stream img.jpg )] ; output file
  (.write w (:body (client/get url {:as :byte-array}  ; here we get
 image as byte-array
))

 Which trlanslates to ( i hope i get it right ) :
 Open file in stream mode (w) and write to it byte stream (image file ) from
 url.


 On Monday, October 15, 2012 1:06:19 PM UTC+4, Yakovlev Roman wrote:

 Hi
 I am pretty new to java world so as i found there is no simple way to get
 image file from url like : http://example.com/image.jpg.
 What i need just to get file from url and store it to db.
 So we need to use buffer, stream and stuff to get file. I found this code
 but i guess there is a way to get things simplier.

 (defn fetch-data [url]
   (let  [con(- url java.net.URL. .openConnection)
  fields (reduce (fn [h v]
   (assoc h (.getKey v) (into [] (.getValue v
 {} (.getHeaderFields con))
  size   (first (fields Content-Length))
  in (java.io.BufferedInputStream. (.getInputStream con))
  out(java.io.BufferedOutputStream.
  (java.io.FileOutputStream. out.file)) ; Here is our
 file
  buffer (make-array Byte/TYPE 1024)]

 ; Not sure about that loop it's just prints size to repl if we don't need
 that we can omit that part i guess

 (loop [g (.read in buffer)
r 0]
   (if-not (= g -1)
 (do
   (println r / size)
   (.write out buffer 0 g)
   (recur (.read in buffer) (+ r g)

 (.close in)
 (.close out)
 (.disconnect con)))

 (fetch-data http://google.com;)


 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
Zhitong He
Sun Yat-sen University

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Making CLJS output smaller

2012-10-16 Thread David Nolen
On Tue, Oct 16, 2012 at 7:19 AM, Herwig Hochleitner
hhochleit...@gmail.comwrote:

 Certainly, such a simple optimization (omitting var reads in a statement
 context) could live in the emitter.
 The next stumbling block to a smaller clojurescript, however, is the
 global-hierarchy var, which doesn't get removed by the closure compiler. To
 shake that var, some closed world optimization could be utilized. I'd be
 happy to work on that, but I need compilation units in order to do that.


I'm aware of this one as well. But again I think we can and should do a
quick fix in the compiler for this. Either the user used multimethods or
they did not.

These kind of simple approaches may seem hacky but I think the benefit to
users in terms of code size today outweighs those concerns - the discussed
fixes would be quite simple to remove when a more general optimization
strategy is in place.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Evaluating an anonymous function with closure

2012-10-16 Thread Jim foo.bar

On 16/10/12 13:20, Michael Gardner wrote:

On Oct 16, 2012, at 5:16 AM, Jim foo.bar wrote:


so you're saying that if I write a for-loop in Java that populates an array 
with constants from 1-1 and then a 2nd loop to add them up, it would happen 
at compile-time and i would get the same timing-result?

Maybe, maybe not. Compilers are very smart these days, but I don't know if they 
can fold complex expressions like for-loops.



I see... so Clojure macros could indeed have the advantage over regular 
Java methods with regards to my trivial example? I do understand that 
most of the times you simply don't have the data at compile time but 
there must be occasions where you do and replacing a complex expression 
with a scalar might provide stunning performance...I've not had the time 
to go back to the project of mine where performance really really 
matters but I will soon do and let you know if I find anything...


thanks again...

Jim

--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Simple way to get image from url

2012-10-16 Thread Jim foo.bar

On 16/10/12 13:25, Zhitong He wrote:

another way to solve this,  from
http://users.utu.fi/machra/posts/2011-08-24-2-reddit-clojure.html

(ns myapp.app
(:require [clojure.java.io :as io]))

  (defn copy [uri file]
  (with-open [in (io/input-stream uri)
  out (io/output-stream file)]
(io/copy in out)))


this looks nice...also, no dependencies - you can run this on your android!

Jim

--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Correct usage of data-readers

2012-10-16 Thread Stuart Sierra
- is it appropriate to include data_readers.clj in a library - given that 
file is in the root?

No. data_readers.clj is intended for application developers. Libraries may 
define data reader functions and suggest tags for consumers of that library.

-S

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Smarter code reloading with tools.namespace 0.2.0

2012-10-16 Thread Stuart Sierra


 #FileNotFoundException java.io.FileNotFoundException: Could not locate 
 clojure/tools/namespace__init.class or *clojure/tools/namespace.clj* on 
 classpath: 


 Now, somewhere in the code, something is looking for 
 clojure.tools.namespace.clj. But that's just a directory in the 
 projecthttps://github.com/clojure/tools.namespace/tree/master/src/main/clojure/clojure/tools/namespace.
  
 I can't see anywhere in the codebase that tries to use or require that 
 file. 


Something must be trying to load 'clojure.tools.namespace', which was a 
real namespace in the tools.namespace 0.1.x releases. Perhaps something in 
Ritz is trying to load it.

-S 

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: ANN: Clojure 1.3 and 1.4 Cheat Sheet v7

2012-10-16 Thread Nick Klauer
I noticed that the PDF downloads seems a bit off.  At least in my case, the 
standard 
PDFhttps://github.com/jafingerhut/clojure-cheatsheets/blob/master/pdf/cheatsheet-usletter-color.pdf?raw=trueleaves
 alot of whitespace.


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Correct usage of data-readers

2012-10-16 Thread Justin Kramer
On Tuesday, October 16, 2012 9:07:49 AM UTC-4, Stuart Sierra wrote:

 - is it appropriate to include data_readers.clj in a library - given that 
 file is in the root?

 No. data_readers.clj is intended for application developers. Libraries may 
 define data reader functions and suggest tags for consumers of that library.
  


Really? So take the ordered library as an example:

https://github.com/flatland/ordered

It defines #ordered/map and #ordered/set. That's not proper usage?

If using data_readers.clj is truly discouraged for libs, that should be 
documented - perhaps in 
http://dev.clojure.org/display/design/Library+Coding+Standards? I can 
update it myself once I understand the rationale.

Justin

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: ANN: Clojure 1.3 and 1.4 Cheat Sheet v7

2012-10-16 Thread Andy Fingerhut
Yes, the PDF versions of the cheat sheet used to fit into 2 A4 or US letter 
sized pages quite nicely, before I started adding more things to it.

Now I'm sure they can fit into 3 such pages quite nicely, but to fit into 2 
would require reducing the font size.  Since it no longer fit into 2, I haven't 
attempted to reorder the content to fit more nicely into 3.

Do you have any use cases for the PDF that the HTML won't do?

Andy

On Oct 16, 2012, at 7:15 AM, Nick Klauer wrote:

 I noticed that the PDF downloads seems a bit off.  At least in my case, the 
 standard PDF leaves alot of whitespace.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Smarter code reloading with tools.namespace 0.2.0

2012-10-16 Thread Timothy Washington
I tracked down the problem. Funny thing is that tools.namespace is failing
when trying to reload the ring component inside of noir. Looking at *
nrepl-ritz.el* (0.5.0), which uses *nrepl.el* (0.1.4), there are a few
references to namespace. But I don't think that has anything to do with
tools.namespace. So the thing trying to call clojure.tools.namespace, was
when the (refresh) stacktrace got to *ring.middleware.reload*. Below is a
curated stacktrace.

nREPL server started on port 42939
java.io.FileNotFoundException: Could not locate
clojure/tools/namespace__init.class or clojure/tools/namespace.clj on
classpath:
at clojure.lang.RT.load(RT.java:432)
at clojure.lang.RT.load(RT.java:400)
at clojure.core$load$fn__4890.invoke(core.clj:5415)
at clojure.core$load.doInvoke(core.clj:5414)
at clojure.lang.RestFn.invoke(RestFn.java:408)
at clojure.core$load_one.invoke(core.clj:5227)
at clojure.core$load_lib.doInvoke(core.clj:5264)
at clojure.lang.RestFn.applyTo(RestFn.java:142)
at clojure.core$apply.invoke(core.clj:603)
at clojure.core$load_libs.doInvoke(core.clj:5298)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.core$apply.invoke(core.clj:605)
at clojure.core$use.doInvoke(core.clj:5392)
at clojure.lang.RestFn.invoke(RestFn.java:482)
at
ns_tracker.core$eval2801$loading__4784__auto2802.invoke(core.clj:1)
at ns_tracker.core$eval2801.invoke(core.clj:1)
at clojure.lang.Compiler.eval(Compiler.java:6511)
...
at clojure.lang.RestFn.invoke(RestFn.java:408)
*at
ring.middleware.reload$eval2795$loading__4784__auto2796.invoke(reload.clj:1)
*
*at ring.middleware.reload$eval2795.invoke(reload.clj:1)*
at clojure.lang.Compiler.eval(Compiler.java:6511)
...
at clojure.lang.RestFn.invoke(RestFn.java:457)
*at
noir.server.handler$eval2789$loading__4784__auto2790.invoke(handler.clj:1)
*
*at noir.server.handler$eval2789.invoke(handler.clj:1)*
at clojure.lang.Compiler.eval(Compiler.java:6511)
...
at clojure.lang.RestFn.invoke(RestFn.java:421)
*at
noir.server$eval2145$loading__4784__auto2146.invoke(server.clj:1)*
*at noir.server$eval2145.invoke(server.clj:1)*
at clojure.lang.Compiler.eval(Compiler.java:6511)
...
*at
clojure.tools.namespace.reload$track_reload_one.invoke(reload.clj:35)*
*at
clojure.tools.namespace.reload$track_reload.invoke(reload.clj:52)*
...
*at
clojure.tools.nrepl.middleware.interruptible_eval$evaluate.invoke(interruptible_eval.clj:42)
*
*at
clojure.tools.nrepl.middleware.interruptible_eval$interruptible_eval$fn__536$fn__538.invoke(interruptible_eval.clj:170)
*
at clojure.core$comp$fn__4034.invoke(core.clj:2278)
at
clojure.tools.nrepl.middleware.interruptible_eval$run_next$fn__529.invoke(interruptible_eval.clj:137)
at clojure.lang.AFn.run(AFn.java:24)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)


Digging through ring code is another kettle of fish. Does ring need to be
updated? If so, tools.namespace will have to deal would these issues on a
library by library basis.


Thanks
Tim



On Tue, Oct 16, 2012 at 9:11 AM, Stuart Sierra
the.stuart.sie...@gmail.comwrote:


 #FileNotFoundException java.io.FileNotFoundException: Could not locate 
 clojure/tools/namespace__init.**class or *clojure/tools/namespace.clj* on 
 classpath: 


 Now, somewhere in the code, something is looking for
 clojure.tools.namespace.clj. But that's just a directory in the 
 projecthttps://github.com/clojure/tools.namespace/tree/master/src/main/clojure/clojure/tools/namespace.
 I can't see anywhere in the codebase that tries to use or require that
 file.


 Something must be trying to load 'clojure.tools.namespace', which was a
 real namespace in the tools.namespace 0.1.x releases. Perhaps something in
 Ritz is trying to load it.

 -S


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Rouge: Ruby + Clojure

2012-10-16 Thread Armando Blancas
Finally came around to install a recent Ruby build and ran a little test 
script just to get a feel for the startup time. Looks good, though the 
faster the merrier.

~ $ ruby --version
ruby 1.9.3p286 (2012-10-12 revision 37165) [x86_64-darwin10.8.0]

~/dev/tools/rouge $ cat test.clj 
(defn square [x] (* x x))

(defn fact [n]
  (if (= n 0)
1
(* n (fact (- n 1)

(print (fact (square 3)))
(print)

~/dev/tools/rouge $ time bin/rouge test.clj
362880
real 0m0.303s
user 0m0.291s
sys 0m0.011s
~/dev/tools/rouge $ time clj test.clj
362880
real 0m1.103s
user 0m1.683s
sys 0m0.127s

On Friday, October 12, 2012 4:40:28 AM UTC-7, Arlen Christian Mart Cuss 
wrote:

 Hi all,

 I'd like to announce Rouge, which is an implementation of Clojure on Ruby.

 https://github.com/unnali/rouge#readme

 The readme above shows example of some Rouge code, most of which is 
 currently taken from the boot file of Rouge itself.  The thing is fully 
 TDDed, so you can read the specs to see how (in)complete it is. :)

 I'd love it if you gave it a try, and let me know your thoughts and 
 feedback.  Even more than that, I'd love your contributions!  Clojure is a 
 beautiful language, and I'm really happy to be able to combine it with my 
 other favourite language.

 Cheers,

 Arlen


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

ANN: Minderbinder v0.2.0

2012-10-16 Thread Fogus
Minderbinder is a Clojure library for defining unit conversions available 
at read, compile and run time. 

More information is available on the [Minderbinder source 
repo](https://github.com/fogus/minderbinder).

Use


Include the following in your 
[Leiningen](https://github.com/technomancy/leiningen) project.clj file:

[fogus/minderbinder 0.2.0]

Or include the following in your pom.xml file in the `dependencies` section:

dependency
  groupIdfogus/groupId
  artifactIdminderbinder/artifactId
  version0.2.0/version
/dependency

Examples


Minderbinder includes unit conversions for the following units of measure:

  * [Time][t]: via `#unit/time`, base is `:milliseconds`, ns is 
`minderbinder.time`
  * [Length][l]: via `#unit/length`, base is `:meters`, ns is 
`minderbinder.length`
  * [Information][i]: via `#unit/info`, base is `:byte`, ns is 
`minderbinder.information`

[t]: 
https://github.com/fogus/minderbinder/blob/master/src/minderbinder/time.clj
[l]: 
https://github.com/fogus/minderbinder/blob/master/src/minderbinder/length.clj
[i]: 
https://github.com/fogus/minderbinder/blob/master/src/minderbinder/information.clj

Using Minderbinder's unit reader form
--

(ns minderbinder.test.core
  (:require minderbinder.time))

(== #unit/time [1 :second]
#unit/time [1000 :ms])

;;= true

(== #unit/time [1 :minute 30 :seconds]
#unit/time [90 :seconds])

;;= true

Using Minderbinder's unit parse functions
-

(ns minderbinder.test.core
  (:require [minderbinder.length :as mbr]))

(mbr/parse-length-unit [1 :km])

;;= 1000

(mbr/parse-length-unit [1 :ramsden-link])

;;= 381/1250

Defining custom conversion rules


Defining a unit conversion is accomplished via Minderbinder's `defunits-of` 
macro.  The body of the macro expects the following structure:

(defunits-of *unit-name* *base-unit-tag* *docstring* *conversion-spec*)

The *conversion spec* part of the body currently allows pairs of mappings 
defined in reletive terms.  The pairs always start with a keyword used as 
the unit tag.  However, the right-hand side of the pair can be one of the 
following:

 1. Number  - defines the value of the unit relative to the base unit
 2. Vector  - defines the value of the unit relative to another contained 
unit
 3. Keyword - defines a single alias for a unit
 4. Set - defined one or more aliases for a unit
 
A simplified version of Minderbinder's length conversion definition serves 
as an example:

(defunits-of length :meter
  The meter is the length of the path 
  traveled by light in vacuum during a 
  time interval of 1/299,792,458 of 
  a second.
   
  :m  :meter   ;; an alias for the base unit
  :km 1000 ;; a larger value relative to the base 
unit
  :km #{kilometer kilometers}  ;; multiple aliases for a unit
  :cm 1/100;; a smaller value relative to the base
  :mm [1/10 :cm])  ;; a value relative to another unit

### Generated vars

The `defunits-of` macro will define three things in the namespace where the 
`defunits-of` macro appears:

 1. `parse-XXX-unit` - a function that parses the unit vector according to 
the conversion spec, returning the total value relative to the base.

 2. `unit-of-XXX`- a macro that allows the for `(unit-of-XXX 1 :foo)` 
that returns the total value relative to the base.
 
 3. `XXX-table`  - a map describing the unit conversion rules.

Contributions welcomed!

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Correct usage of data-readers

2012-10-16 Thread Stuart Sierra
One data_readers.clj file can't override another: it's an error if they 
contain the same tags with different functions. So if a library defines its 
data reader tags, you can't override them *at read-time* in your app.

You can always override readers dynamically at run-time by binding 
*data-readers*.

-S

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Making CLJS output smaller

2012-10-16 Thread Herwig Hochleitner
2012/10/16 David Nolen dnolen.li...@gmail.com


 I'm aware of this one as well. But again I think we can and should do a
 quick fix in the compiler for this. Either the user used multimethods or
 they did not.


I don't see how such a quick fix could be done, without the compiler
gaining a concept of the whole program, in which the user could have used
MMs.
In my understanding, the compiler, as it is right now, is fundamentally
form-at-a-time, so at the point the global-hierarchy var already gets
emitted, you can't possibly know if it will be used.
Certainly, you are much more familiar with the implementation, do you see a
point where this could already be hacked in?


  These kind of simple approaches may seem hacky but I think the benefit
 to users in terms of code size today outweighs those concerns - the
 discussed fixes would be quite simple to remove when a more general
 optimization strategy is in place.


To be honest, the introduction of compile-unit is the simplest, most
general solution I could come up with after some hammock time. Since it
seems not to be an obiously bad idea, I'll stop here and get back to
confluence with a fully thought out  proposal + implementation. Feedback
and alternate approaches still welcome.

2012/10/16 Andy Fingerhut andy.finger...@gmail.com

 Herwig:

 I've added you to a couple of groups (clojure-dev and jira-developers) on
 Confluence that you did not previously belong to.  I'm not sure, but this
 may give you permission to edit Confluence.  Let me know if you still
 cannot do so after receiving this message.


Thank you! Unfortunately that didn't seem to help. In the top bar I have 2
menus Browse and my account. The tools menu on each page doesn't let me
edit either.

kind regards

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Making CLJS output smaller

2012-10-16 Thread David Nolen
On Tue, Oct 16, 2012 at 12:27 PM, Herwig Hochleitner hhochleit...@gmail.com
 wrote:

 2012/10/16 David Nolen dnolen.li...@gmail.com


 I'm aware of this one as well. But again I think we can and should do a
 quick fix in the compiler for this. Either the user used multimethods or
 they did not.


 I don't see how such a quick fix could be done, without the compiler
 gaining a concept of the whole program, in which the user could have used
 MMs.
 In my understanding, the compiler, as it is right now, is fundamentally
 form-at-a-time, so at the point the global-hierarchy var already gets
 emitted, you can't possibly know if it will be used.
 Certainly, you are much more familiar with the implementation, do you see
 a point where this could already be hacked in?


ClojureScript programmers benefit from the assumption of whole program
optimization for production code. Also remember we have analyze-file.

If these weren't true ClojureScript would not be anywhere near as fast as
it currently is. Look at all the assumptions we can make when we compile a
fn invocation form under advanced compilation.

David

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Rouge: Ruby + Clojure

2012-10-16 Thread Phil Hagelberg
On Fri, Oct 12, 2012 at 4:40 AM, Arlen Christian Mart Cuss a...@len.me wrote:
 I'd like to announce Rouge, which is an implementation of Clojure on Ruby.

Interesting project.

What are you planning on doing about the fact that Ruby has mutable
strings? Seems like that would be a deal-breaker for implementing
Clojure's equality semantics.

http://home.pipeline.com/~hbaker1/ObjectIdentity.html

-Phil

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Making CLJS output smaller

2012-10-16 Thread Herwig Hochleitner
2012/10/16 David Nolen dnolen.li...@gmail.com


 ClojureScript programmers benefit from the assumption of whole program
 optimization for production code. Also remember we have analyze-file.


They most certainly do, but in my mind this assumption is only made in the
google closure compiler, right now.
I see analyze-file is used in the compiler to prepopulate an analysis
environment with clojure.core. It still doesn't look at the whole program
at once.
IMO it wouldn't be a good fit to base optimizations on, since that would
hardcode a compilation unit to be a file. Also, you couldn't remove
multimethod infrastructure with it, since it would only know about a file
at a time.


 If these weren't true ClojureScript would not be anywhere near as fast as
 it currently is. Look at all the assumptions we can make when we compile a
 fn invocation form under advanced compilation.


Are you are talking about compile time optimization for invokations of
fixed arity, protocols, keywords and clojure.core/not, by chance? Those are
fine optimizations, but they don't depend on WPO or advanced mode.
In my mental model, the cljs compiler generates the same intermediate
javascript in all optimization levels. I have looked at
cljs.analyzer/parse-invoke and cljs.compiler/emit :invoke but couldn't find
any different code paths. Am I missing something?

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Making CLJS output smaller

2012-10-16 Thread David Nolen
None of the invocation optimizations make any sense for anything other that
advanced optimization. They hard code static assumptions that might get
invalidated in any compilation unit other than whole program.

We don't need to look at the whole program at once. Think about why we need
declare and most Clojure programs avoid it if they can.

I don't think we need any fancy compiler stuff to fix the two big dead code
issues in the near term.

On Tuesday, October 16, 2012, Herwig Hochleitner wrote:

 2012/10/16 David Nolen dnolen.li...@gmail.com javascript:_e({}, 'cvml',
 'dnolen.li...@gmail.com');


 ClojureScript programmers benefit from the assumption of whole program
 optimization for production code. Also remember we have analyze-file.


 They most certainly do, but in my mind this assumption is only made in the
 google closure compiler, right now.
 I see analyze-file is used in the compiler to prepopulate an analysis
 environment with clojure.core. It still doesn't look at the whole program
 at once.
 IMO it wouldn't be a good fit to base optimizations on, since that would
 hardcode a compilation unit to be a file. Also, you couldn't remove
 multimethod infrastructure with it, since it would only know about a file
 at a time.


 If these weren't true ClojureScript would not be anywhere near as fast as
 it currently is. Look at all the assumptions we can make when we compile a
 fn invocation form under advanced compilation.


 Are you are talking about compile time optimization for invokations of
 fixed arity, protocols, keywords and clojure.core/not, by chance? Those are
 fine optimizations, but they don't depend on WPO or advanced mode.
 In my mental model, the cljs compiler generates the same intermediate
 javascript in all optimization levels. I have looked at
 cljs.analyzer/parse-invoke and cljs.compiler/emit :invoke but couldn't find
 any different code paths. Am I missing something?

  --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to 
 clojure@googlegroups.comjavascript:_e({}, 'cvml', 
 '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
 clojure+unsubscr...@googlegroups.com javascript:_e({}, 'cvml',
 'clojure%2bunsubscr...@googlegroups.com');
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

trampoline not compatible with reducers?

2012-10-16 Thread Jim - FooBar();

Hi everyone,

I'm pretty sure i'm using trampoline the right way but still I get this 
exception:


ClassCastException Clondie24.lib.search$search$minimize__3075$fn__3076 
cannot be cast to java.lang.Number  
Clondie24.lib.search/search/minimize--3075 (search.clj:47)


here is the code:

(defn search The recursive bit of the min-max algorithm.
[eval-fn tree depth]
(letfn [(minimize ^double [tree d] (if (zero? d) (eval-fn (:root tree) 
(:direction tree))

#(r/reduce my-min
  (r/map (fn [child] (maximize (:tree 
child) (dec d))) (:children tree)
(maximize ^double [tree d] (if (zero? d) (eval-fn (:root tree) 
(:direction tree))

#(r/reduce my-max
   (r/map (fn [child] (minimize (:tree 
child) (dec d))) (:children tree)]

(trampoline minimize tree (int depth

Can anyone shine some light? Is it something that has to do with reducers?

Jim

ps: it works fine without trampoline and '#' behind 'r/reduce'.




--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: trampoline not compatible with reducers?

2012-10-16 Thread Kevin Downey
you are declaring the functions return doubles, but in fact returning
functions or doubles

On Tue, Oct 16, 2012 at 11:06 AM, Jim - FooBar(); jimpil1...@gmail.com wrote:
 Hi everyone,

 I'm pretty sure i'm using trampoline the right way but still I get this
 exception:

 ClassCastException Clondie24.lib.search$search$minimize__3075$fn__3076
 cannot be cast to java.lang.Number
 Clondie24.lib.search/search/minimize--3075 (search.clj:47)

 here is the code:

 (defn search The recursive bit of the min-max algorithm.
 [eval-fn tree depth]
 (letfn [(minimize ^double [tree d] (if (zero? d) (eval-fn (:root tree)
 (:direction tree))
 #(r/reduce my-min
   (r/map (fn [child] (maximize (:tree child)
 (dec d))) (:children tree)
 (maximize ^double [tree d] (if (zero? d) (eval-fn (:root tree)
 (:direction tree))
 #(r/reduce my-max
(r/map (fn [child] (minimize (:tree
 child) (dec d))) (:children tree)]
 (trampoline minimize tree (int depth

 Can anyone shine some light? Is it something that has to do with reducers?

 Jim

 ps: it works fine without trampoline and '#' behind 'r/reduce'.




 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
And what is good, Phaedrus,
And what is not good—
Need we ask anyone to tell us these things?

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: trampoline not compatible with reducers?

2012-10-16 Thread Jim - FooBar();

On 16/10/12 19:15, Kevin Downey wrote:

you are declaring the functions return doubles, but in fact returning
functions or doubles
yes you're right (my bad) but the same thing happens without the 
type-hinting - albeit in a different place and different originating 
function:


ClassCastException Clondie24.lib.search$search$maximize__3081$fn__3082 
cannot be cast to java.lang.Number  clojure.lang.Numbers.lt 
(Numbers.java:219)


Jim



--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Rouge: Ruby + Clojure

2012-10-16 Thread Arlen Cuss
Hi Phil,


On Wednesday, 17 October 2012 at 4:11 AM, Phil Hagelberg wrote:

 Interesting project.
Thanks!
 
 What are you planning on doing about the fact that Ruby has mutable
 strings? Seems like that would be a deal-breaker for implementing
 Clojure's equality semantics.
 
 http://home.pipeline.com/~hbaker1/ObjectIdentity.html
My initial solution is to freeze all strings in the reader.  This prevents the 
most obvious issues, as it means any string read in from the Rouge code itself 
is immutable.

The wider question of strings in Rouge code in general is going to be a 
concern, and something I'll probably have to mull over more shortly. :)  There 
are some options (which I don't quite like), such as freezing strings on entry 
to Rouge code and duping them on exit.

- Arlen

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Making CLJS output smaller

2012-10-16 Thread Herwig Hochleitner
2012/10/16 David Nolen dnolen.li...@gmail.com

 None of the invocation optimizations make any sense for anything other
 that advanced optimization.


But the invokations in javascript output work even when not using google
closure at all, e.g. the REPL.


 They hard code static assumptions that might get invalidated in any
 compilation unit other than whole program.

 Partially agree: I would call those hard coded static assumptions an ABI
(e.g. the naming convention for fixed arity invokations, or the invokation
of a protocol fn) and compilation units would only work, when the APIs they
consume have a matching ABI (this is true even now, you wouldn't compile
parts of your project with different versions of clojurescript, would you?).


 We don't need to look at the whole program at once. Think about why we
 need declare and most Clojure programs avoid it if they can.


We need declare, because clojure features a single pass compiler, and
sometimes we want to code mutual recursion without letfn. The moral
equivalent for the MM dead code issue would be a compiler flag to turn off
multimethods, right?. Certainly doable. If you'd like me to implement that
flag before turning to more comprehensive optimization, I'll do it.

So yes, if we want to eliminate more dead code without having the user
manually turn off features, I think we do need to look at the whole
program, don't we?

Please also note: I'm not proposing to get rid of the single pass semantics
of clojure. Quite the opposite. After the analyzer is done with its single
pass and has unambigously resolved everything, optimization passes are free
to optimize, since the semantics are already established.


 I don't think we need any fancy compiler stuff to fix the two big dead
 code issues in the near term.


I agree that the unused read issue can be generically solved in the
emitter. For the one with unused toplevel vars like global-hierachy, I'm
not so sure, especially if we also want to solve the problem for libraries,
which arguably is a goal of clojurescript.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Making CLJS output smaller

2012-10-16 Thread David Nolen
On Tue, Oct 16, 2012 at 2:41 PM, Herwig Hochleitner
hhochleit...@gmail.comwrote:

 2012/10/16 David Nolen dnolen.li...@gmail.com

 None of the invocation optimizations make any sense for anything other
 that advanced optimization.


 But the invokations in javascript output work even when not using google
 closure at all, e.g. the REPL.


Yes because we don't try to optimize them.




 They hard code static assumptions that might get invalidated in any
 compilation unit other than whole program.

 Partially agree: I would call those hard coded static assumptions an ABI
 (e.g. the naming convention for fixed arity invokations, or the invokation
 of a protocol fn) and compilation units would only work, when the APIs they
 consume have a matching ABI (this is true even now, you wouldn't compile
 parts of your project with different versions of clojurescript, would you?).


Start a CLJS REPL with :static-fns true. Make a function called foo. Call
it from a function bar. Redef foo w/ different arities. Now call bar. This
will not work. Same if you redef foo to be an instance of a deftype that
implements IFn.


 We need declare, because clojure features a single pass compiler, and
 sometimes we want to code mutual recursion without letfn. The moral
 equivalent for the MM dead code issue would be a compiler flag to turn off
 multimethods, right?. Certainly doable. If you'd like me to implement that
 flag before turning to more comprehensive optimization, I'll do it.


Either the user used multimethods or they did not. If they did emit the
hierarchy. And only bother with this code size optimization during advanced
compilation - just always emit the hierarchy otherwise.


 Please also note: I'm not proposing to get rid of the single pass
 semantics of clojure. Quite the opposite. After the analyzer is done with
 its single pass and has unambigously resolved everything, optimization
 passes are free to optimize, since the semantics are already established.


Nothing I've said has anything do w/ optimization passes. Just how
immediate problems could be solved without waiting for that ;)

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: trampoline not compatible with reducers?

2012-10-16 Thread Kevin Downey
if you look further down the stacktrace (where it refers to your code
instead of clojure.lang.Numbers.lt) it will give you line numbers in
your code to look at.

you are calling these trampolined functions without trampoline.

On Tue, Oct 16, 2012 at 11:24 AM, Jim - FooBar(); jimpil1...@gmail.com wrote:
 On 16/10/12 19:15, Kevin Downey wrote:

 you are declaring the functions return doubles, but in fact returning
 functions or doubles

 yes you're right (my bad) but the same thing happens without the
 type-hinting - albeit in a different place and different originating
 function:

 ClassCastException Clondie24.lib.search$search$maximize__3081$fn__3082
 cannot be cast to java.lang.Number  clojure.lang.Numbers.lt
 (Numbers.java:219)

 Jim




 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
And what is good, Phaedrus,
And what is not good—
Need we ask anyone to tell us these things?

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Smarter code reloading with tools.namespace 0.2.0

2012-10-16 Thread Stuart Sierra
'ring-devel' depends on 'ns-tracker', which uses tools.namespace 0.1.3:
https://github.com/weavejester/ns-tracker/blob/master/project.clj

Dependency resolution will only allow one version of the library, so your 
project gets tools.namespace 0.2.0, not 0.1.3. The two releases are not 
compatible, which is documented in the README.

This will have to be fixed in ring-devel and/or ns-tracker.

-S

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: trampoline not compatible with reducers?

2012-10-16 Thread Jim - FooBar();
'my-min' and 'my-max' simply wrap core/min core/max. You mean i have to 
trampoline these calls as well? return something like this? :


#(r/reduce (trampoline my-max) ;;was my-max
   (r/map (fn [child] (minimize (:tree 
child) (dec d))) (:children tree)))


Jim


On 16/10/12 20:01, Kevin Downey wrote:

if you look further down the stacktrace (where it refers to your code
instead of clojure.lang.Numbers.lt) it will give you line numbers in
your code to look at.

you are calling these trampolined functions without trampoline.

On Tue, Oct 16, 2012 at 11:24 AM, Jim - FooBar(); jimpil1...@gmail.com wrote:

On 16/10/12 19:15, Kevin Downey wrote:

you are declaring the functions return doubles, but in fact returning
functions or doubles

yes you're right (my bad) but the same thing happens without the
type-hinting - albeit in a different place and different originating
function:

ClassCastException Clondie24.lib.search$search$maximize__3081$fn__3082
cannot be cast to java.lang.Number  clojure.lang.Numbers.lt
(Numbers.java:219)

Jim




--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en





--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


[ANN] Immutant 0.5.0 released

2012-10-16 Thread Toby Crawley
We released Immutant 0.5.0 today, with a few bugfixes and some new features. 
Some notable changes:

* You can now easily run your tests inside the Immutant container via `lein 
immutant test`
* We expose the Quartz job schedulers for each app, allowing you to use 
Quartzite instead of the Immutant job api, 
 while still taking advantage of singleton jobs within a cluster

We're hoping to have something we can call 1.0 by late fall or early winter (in 
the northern hemisphere, that is).

Learn more at http://bit.ly/immutant050

# What is Immutant?

Immutant is an application server for Clojure. It's an integrated platform 
built on JBoss AS7 that aims to reduce the incidental complexity in real-world 
applications. It provides support for Ring handlers, asynchronous messaging, 
caching, scheduled jobs, XA transactions, clustering, and daemons.

Let us know if you have any questions or issues.

---
Toby Crawley
http://torquebox.org | http://immutant.org

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Smarter code reloading with tools.namespace 0.2.0

2012-10-16 Thread Hugo Duncan
Timothy Washington twash...@gmail.com writes:

 2) Running emacs with nrepl.el. I fire up *M-x nrepl-ritz-jack-in*

ritz-repl-utils includes a namespace dependency graph in
ritz.repl-utils.namespaces.  It doesn't yet include a refresh type
function, but that would be straightforward to add on top of a call to
`(transitive-dependencies (direct-dependencies))`.

Hugo

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


ANN: zombie 0.2.0

2012-10-16 Thread XPherior
Zombie is a Clojure framework for semantic transformations of map-based 
data.
It's often useful in testing to abstractly state how two pieces of data are 
different, rather
than explicitly conjure up concrete values. I hope this helps to capture 
the essence of tests
better, especially for tests that persist a plethora of data and perform 
queries to retrieve it.

https://github.com/MichaelDrogalis/zombie

Suggestions very much welcomed to make this better. :)

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

parallel alpha-beta pruning possible?

2012-10-16 Thread Jim - FooBar();
After watching this presentation[1] by Brian Goetz, in which he 
discusses the fork-join framework and how it is intended to be used I 
was left with a major question. Around the end of the talk he said and I 
quote


...fork-join can be used for game-tree exploration...

while the slides actually had
-Move generation
-Alpha-beta
...


As soon as I saw/heard that I almost fell of my chair!!! He caught me 
completely by surprise simply because I've given this quite a bit of 
though myself... NOw, I'm not implying that I am nowhere near as smart 
or informed as he is but the 'objection' I have is pretty simple. I 
already have a parallel minimax (some of you have actually helped) so I 
know how that's done and it wasn't too hard because minimax is 
exhaustive search. No heuristics whatsoever...as long as you work with 
immutable data-structures God is on your side and all is well!


HOWEVER, as soon as you introduce heuristics (even simplistic like 
alpha-beta pruning) you 've lost the ability to split the work in 
pieces. You've suddenly introduced coordination which only makes sense 
in a serial fashion. Since pruning a particular branch of the game-tree 
requires knowing how the previous branch did  how can you ever fork? 
What if these 2 branches are on separate threads? How can you ever do 
that without locking?


I am very excited that someone like Brian Goetz is claiming something 
like this even though I don't understand how such an inherently serial 
process could be efficiently forked.


Can anyone help?


 [1] http://www.infoq.com/presentations/brian-goetz-concurrent-parallel

Jim

--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: [ANN] Immutant 0.5.0 released

2012-10-16 Thread Simone Mosciatti
It looks great, well done...

waiting for the 1.0...

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: trampoline not compatible with reducers?

2012-10-16 Thread Alan Malloy
Reducers don't enter into the picture at all: this code is just as
broken with clojure.core/reduce and clojure.core/map. The immediate
problem that Kevin is trying to draw your attention to is that you are
calling (reduce max (map my-fn coll)), where my-fn sometimes returns a
number, and sometimes a thunk. Obviously max can't be expected to
compare thunks for you, so that's no good. His suggestion is to make
sure to trampoline the results of (map my-fn coll) until you get out a
list of numbers, and then find the max.

But really I don't think trampoline is a very compelling problem-
solver here: the primary (only?) gain from trampoline is in reducing
stack depth, and I rather doubt that you can calculate minimax for
even a few hundred ply. So you're in no danger of a stackoverflow, but
are sacrificing readability and a smidge of performance to keep your
stack really small instead of not big enough to be a problem.

On Oct 16, 12:45 pm, Jim - FooBar(); jimpil1...@gmail.com wrote:
 'my-min' and 'my-max' simply wrap core/min core/max. You mean i have to
 trampoline these calls as well? return something like this? :

 #(r/reduce (trampoline my-max) ;;was my-max
                                     (r/map (fn [child] (minimize (:tree
 child) (dec d))) (:children tree)))

 Jim

 On 16/10/12 20:01, Kevin Downey wrote:







  if you look further down the stacktrace (where it refers to your code
  instead of clojure.lang.Numbers.lt) it will give you line numbers in
  your code to look at.

  you are calling these trampolined functions without trampoline.

  On Tue, Oct 16, 2012 at 11:24 AM, Jim - FooBar(); jimpil1...@gmail.com 
  wrote:
  On 16/10/12 19:15, Kevin Downey wrote:
  you are declaring the functions return doubles, but in fact returning
  functions or doubles
  yes you're right (my bad) but the same thing happens without the
  type-hinting - albeit in a different place and different originating
  function:

  ClassCastException Clondie24.lib.search$search$maximize__3081$fn__3082
  cannot be cast to java.lang.Number  clojure.lang.Numbers.lt
  (Numbers.java:219)

  Jim

  --
  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
  clojure+unsubscr...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: parallel alpha-beta pruning possible?

2012-10-16 Thread Alan Malloy
You will get better results from a game-programming forum, or indeed
from a google search for parallel alpha beta than from a bunch of
clojure guys with no particular experience in your problem domain.

On Oct 16, 1:27 pm, Jim - FooBar(); jimpil1...@gmail.com wrote:
 After watching this presentation[1] by Brian Goetz, in which he
 discusses the fork-join framework and how it is intended to be used I
 was left with a major question. Around the end of the talk he said and I
 quote

 ...fork-join can be used for game-tree exploration...

 while the slides actually had
 -Move generation
 -Alpha-beta
 ...
 

 As soon as I saw/heard that I almost fell of my chair!!! He caught me
 completely by surprise simply because I've given this quite a bit of
 though myself... NOw, I'm not implying that I am nowhere near as smart
 or informed as he is but the 'objection' I have is pretty simple. I
 already have a parallel minimax (some of you have actually helped) so I
 know how that's done and it wasn't too hard because minimax is
 exhaustive search. No heuristics whatsoever...as long as you work with
 immutable data-structures God is on your side and all is well!

 HOWEVER, as soon as you introduce heuristics (even simplistic like
 alpha-beta pruning) you 've lost the ability to split the work in
 pieces. You've suddenly introduced coordination which only makes sense
 in a serial fashion. Since pruning a particular branch of the game-tree
 requires knowing how the previous branch did  how can you ever fork?
 What if these 2 branches are on separate threads? How can you ever do
 that without locking?

 I am very excited that someone like Brian Goetz is claiming something
 like this even though I don't understand how such an inherently serial
 process could be efficiently forked.

 Can anyone help?

   [1]http://www.infoq.com/presentations/brian-goetz-concurrent-parallel

 Jim

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: parallel alpha-beta pruning possible?

2012-10-16 Thread Jim - FooBar();

On 16/10/12 21:48, Alan Malloy wrote:

You will get better results from a game-programming forum, or indeed
from a google search for parallel alpha beta than from a bunch of
clojure guys with no particular experience in your problem domain.


The question is more around JDK7 and reducers. Google gives me loads of 
results but it's all the traditional 'lock and suffer' approach. What I 
meant is basically this:


let's forget about parallelism for a second...once someone has minimax 
ready it is a matter of minutes to turn it into an alpha-beta but in 
doing so you introduce dependencies between the branches and this is 
fine in a serial scenario. The minute forking occurs however you lose 
coordination capabilities (at least this is my understanding). He said 
it very casually in the video that is why this has been bugging me  so 
much...


obviously I'm wrong I'm just trying to find someone that knows a lot 
around reducers/fork-join t give me clues...thanks for your time anyway :-)


Jim

--
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: parallel alpha-beta pruning possible?

2012-10-16 Thread Jack Moffitt
 scenario. The minute forking occurs however you lose coordination
 capabilities (at least this is my understanding). He said it very casually
 in the video that is why this has been bugging me  so much...

Fork/Join is just threads, so I'm not sure why you'd lose coordination
capabilities. You can use all the normal coordination stuff like locks
and mutexes, etc.  Granted, it won't be pretty :)

jack.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


ANN: LibTetris and cljs-tetris

2012-10-16 Thread Andreas Liljeqvist
So the time had come to make a library version of my Tetris-project.

[libtetris 0.1.0]

github: https://github.com/bonega/libtetrishttps://github.com/bonega/libtetris

There is even some
documentationhttp://bonega.github.com/libtetris/index.htmlthanks to
Marginalia.

I have ported my Clojurescript-tetris to use said library.

https://github.com/bonega/cljs-tetris

Play it here: http://bonega.github.com/cljs-tetris/index.html

Libtetris have no dependencies on Clojurescript, it is a standard Clojure
library.
I am very satisfied that we can develop our backbone libraries mostly in
isolation and then reuse them in Clojurescript with crossover.

Have fun.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

AOT-compilation, record types and DynamicClassLoader

2012-10-16 Thread Chris Jeris
I have a problem where I am trying to do an isa? or instance? check on an
object of a record type which is defined in an AOT-compiled namespace.  The
isa? check fails because -- under circumstances which I do not yet well
understand -- the object I actually have is an instance of its class in a
clojure.lang.DynamicClassLoader, whereas a reference to the class by its
literal name yields the class in the base sun.misc.Launcher$AppClassLoader.

My Clojure code is compiled into a jar which is included into a Jetty
server whose app code is largely written in Java.  Here is an example which
illustrates the problem:

;; src/foo/core.clj
(ns foo.core)
(defrecord T [a b])

;; project.clj
(defproject foo 1.0.0-SNAPSHOT
  :dependencies [[org.clojure/clojure 1.4.0]]
  :aot [foo.core])

Now if I add the artifact foo/foo as a Maven dependency of the Jetty
server, and attach a liverepl to the running server (without taking any
action to call the Clojure code from Java), I see the following:

Clojure 1.4.0
user= (require '[foo.core])
nil
user= (.getClassLoader foo.core.T)
#AppClassLoader sun.misc.Launcher$AppClassLoader@a6eb38a
user= (.getClassLoader (type (foo.core.T. 1 2)))
#AppClassLoader sun.misc.Launcher$AppClassLoader@a6eb38a
user= (.getClassLoader (type (foo.core/-T 1 2)))
#DynamicClassLoader clojure.lang.DynamicClassLoader@433d3253

My actual case is more complicated, but the principle is the same:
instances of foo.core.T which were built by the defrecord constructor
function -T do not inhabit the AppClassLoader version of the class, but
rather a DynamicClassLoader version.  The result is that instance? or
instanceof checks -- whether in my own Clojure code or in that of Java
clients of my library who are trying to downcast -- do not behave as
expected.

This example cannot be reduced too far:  if one just builds an uberjar and
invokes a repl on the Clojure library alone, using 'java -cp
target/foo-1.0.0-SNAPSHOT-standalone.jar clojure.main', the result is
different:

Clojure 1.4.0
user= (require '[foo.core])
nil
user= (.getClassLoader foo.core.T)
#AppClassLoader sun.misc.Launcher$AppClassLoader@43be2d65
user= (.getClassLoader (type (foo.core.T. 1 2)))
#AppClassLoader sun.misc.Launcher$AppClassLoader@43be2d65
user= (.getClassLoader (type (foo.core/-T 1 2)))
#AppClassLoader sun.misc.Launcher$AppClassLoader@43be2d65

Unfortunately I don't understand enough about the Clojure class loading
mechanism to understand what might be causing the DynamicClassLoader to be
invoked in one case and not the other.

This problem seems to have been described by Ryan Senior about 20 months
ago on clojure-dev, but I do not find any follow-up posts:
https://groups.google.com/forum/?fromgroups=#!topic/clojure-dev/VBJFMEFBeFY

Can anyone shed light on the situation?

thanks, Chris Jeris
-- 
Chris Jeris
cje...@brightcove.com (617) 686-3271
freenode/twitter/github: ystael

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Making CLJS output smaller

2012-10-16 Thread Herwig Hochleitner
2012/10/16 David Nolen dnolen.li...@gmail.com


 But the invokations in javascript output work even when not using google
 closure at all, e.g. the REPL.


 Yes because we don't try to optimize them.


And suppose one tried to optimize them: With an established concept of
compilation units, it's straightforward to optimize invokations within a
unit and keep a compatible invokation ABI of its public members with
following effect:

- single form units (REPL) work
- whole program units (Clojurescript) work
- namespace/file units (Clojurescript with a JVM backend, hypothetically)
work

Again, getting ahead of myself here.


 Start a CLJS REPL with :static-fns true. Make a function called foo. Call
 it from a function bar. Redef foo w/ different arities. Now call bar. This
 will not work. Same if you redef foo to be an instance of a deftype that
 implements IFn.


Thanks for raising that point. So IFn call is different from an aritiy call
is different from a protocol call in clojurescripts informally defined ABI
(with :static-fns). This has to be considered when thinking about
compilation units.


  We need declare, because clojure features a single pass compiler, and
 sometimes we want to code mutual recursion without letfn. The moral
 equivalent for the MM dead code issue would be a compiler flag to turn off
 multimethods, right?. Certainly doable. If you'd like me to implement that
 flag before turning to more comprehensive optimization, I'll do it.


 Either the user used multimethods or they did not. If they did emit the
 hierarchy. And only bother with this code size optimization during advanced
 compilation - just always emit the hierarchy otherwise.


The emitter still can not look ahead in its single pass, but thinking about
it, it seems to me your proposal could be implemented by lazily
initializing global-hierachy in derive.


 Please also note: I'm not proposing to get rid of the single pass
 semantics of clojure. Quite the opposite. After the analyzer is done with
 its single pass and has unambigously resolved everything, optimization
 passes are free to optimize, since the semantics are already established.


 Nothing I've said has anything do w/ optimization passes. Just how
 immediate problems could be solved without waiting for that ;)


Ack, I think I'll try the two simple fixes first ;)

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Making CLJS output smaller

2012-10-16 Thread David Nolen
On Tue, Oct 16, 2012 at 5:38 PM, Herwig Hochleitner
hhochleit...@gmail.comwrote:


 The emitter still can not look ahead in its single pass, but thinking
 about it, it seems to me your proposal could be implemented by lazily
 initializing global-hierachy in derive.


Sounds good!




 Please also note: I'm not proposing to get rid of the single pass
 semantics of clojure. Quite the opposite. After the analyzer is done with
 its single pass and has unambigously resolved everything, optimization
 passes are free to optimize, since the semantics are already established.


 Nothing I've said has anything do w/ optimization passes. Just how
 immediate problems could be solved without waiting for that ;)


 Ack, I think I'll try the two simple fixes first ;)

 ;)

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: A/B testing in Clojure?

2012-10-16 Thread millettjon
I haven't but will be needing to do so in the next month or two. I'd be 
interested to hear if you made any progress and possibly in collaborating.

Jon

On Monday, October 8, 2012 11:04:10 AM UTC-3, Simon Holgate wrote:

 Hi,

 Is anyone doing split (A/B) testing in Clojure? What are you using? Any 
 pointers on things to consider if I'm implementing it myself?

 Thanks,

 Simon


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Hiccup - HTML - PNG

2012-10-16 Thread nchurch
Has anyone generated PNGs (or any image) from Hiccup in Clojure?  I
see an older Java library for this:

http://code.google.com/p/java-html2image/

Curious to hear about any experience with this library, or if there is
a better solution out there.

Thanks,

Nick.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: parallel alpha-beta pruning possible?

2012-10-16 Thread Michael Fogus
I would probably look at the work that Robert Hyatt has done around
parallel search in Crafty. He's published his findings far and wide and may
still be active online. He's a wealth of information and fairly nice guy.

-- 
-- http://blog.fogus.me
-- http://github.com/fogus
--

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

gen-class :exposes field access

2012-10-16 Thread queshaw
Hi,

I'm trying to create a class, instances of which need to access protected 
fields of the superclass's superclass. But, I am failing so far. Is this a 
bug or am I doing something wrong:

java:

package com.example;

public class Example {

protected static String PROTECTED_FIELD = this is a field;

public void asdf() { }
}

clojure:

(ns test.example
 (:import (com.example Example)))

(gen-class
  :name test.Example
  :extends com.example.Example
  :main false
  :exposes {PROTECTED_FIELD {:get getProtectedField :set setProtectedField}}
  :methods [[fieldInfo [] void]])

(defn -fieldInfo [this]
  (println (.getProtectedField this)))

java:

Example e = new Example();
e.fieldInfo();

results in:

Exception in thread main java.lang.IllegalArgumentException: No matching 
field found: getProtectedField for class test.Example
at clojure.lang.Reflector.getInstanceField(Reflector.java:271)
at clojure.lang.Reflector.invokeNoArgInstanceMember(Reflector.java:300)
at test.example$_fieldInfo.invoke(example.clj:16)
at test.Example.fieldInfo(Unknown Source)
at tests.Tests.main(Tests.java:47)

Oddly also, this:

  System.out.println(e.getProtectedField());

prints the field.

I've tried numerous variations on this.

Do you have any ideas before I file a bug? (aside from make a wrapper 
class).


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Cdr car

2012-10-16 Thread Curtis
Hello - I was familar with lisp years ago and am very new to clojure.

I am having a hard time understanding how to find 'car' and 'cdr'.

The nice thing about these functions is they always seem to be a part of 
lisp.

I would like to use the little lisper to teach lisp to my co-workers so 
that we can adopt Clojure.

How can i import cdr or car? 

I know i can write these manually  or alias them to 'first' and 'rest' - 
are they a part of the language?

Cons appears to be around.



-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Cdr car

2012-10-16 Thread Baishampayan Ghose
`car` is called `first` here and `cdr` could mean either `rest` or
`next` depending on what you mean/need.

And oh, `cons` is not exactly the same one from Common Lisp, etc.

Regards,
BG

On Tue, Oct 16, 2012 at 3:40 PM, Curtis cur...@ram9.cc wrote:
 Hello - I was familar with lisp years ago and am very new to clojure.

 I am having a hard time understanding how to find 'car' and 'cdr'.

 The nice thing about these functions is they always seem to be a part of
 lisp.

 I would like to use the little lisper to teach lisp to my co-workers so that
 we can adopt Clojure.

 How can i import cdr or car?

 I know i can write these manually  or alias them to 'first' and 'rest' - are
 they a part of the language?

 Cons appears to be around.



 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
Baishampayan Ghose
b.ghose at gmail.com

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Cdr car

2012-10-16 Thread Andy Fingerhut
Curtis:

You can do this if you want:

(def car first)
(def cdr rest)

but most people accustomed to Clojure would be much more familiar with first 
and rest.  The Content of the Address and Data Registers haven't been 
applicable for a long time, but it wasn't only the names that are changed -- 
first and rest work on all kinds of data structures besides lists, and return 
implementations of a sequence abstraction, not necessarily pointers to cons 
cells.

Andy

On Oct 16, 2012, at 3:40 PM, Curtis wrote:

 Hello - I was familar with lisp years ago and am very new to clojure.
 
 I am having a hard time understanding how to find 'car' and 'cdr'.
 
 The nice thing about these functions is they always seem to be a part of lisp.
 
 I would like to use the little lisper to teach lisp to my co-workers so that 
 we can adopt Clojure.
 
 How can i import cdr or car? 
 
 I know i can write these manually  or alias them to 'first' and 'rest' - are 
 they a part of the language?
 
 Cons appears to be around.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Cdr car

2012-10-16 Thread kovas boguta
A number of classic lisp books have been translated to clojure, for instance

http://juliangamble.com/blog/2012/07/20/the-little-schemer-in-clojure/

Personally I felt relieved when I saw that clojure had abandoned the
anachronistic car/cdr stuff; the sequence abstraction is a lot nicer.

There are also a number of excellent clojure books you might want to
check out as well, which might appeal to the more practical minded
among the coworkers.



On Tue, Oct 16, 2012 at 6:40 PM, Curtis cur...@ram9.cc wrote:
 Hello - I was familar with lisp years ago and am very new to clojure.

 I am having a hard time understanding how to find 'car' and 'cdr'.

 The nice thing about these functions is they always seem to be a part of
 lisp.

 I would like to use the little lisper to teach lisp to my co-workers so that
 we can adopt Clojure.

 How can i import cdr or car?

 I know i can write these manually  or alias them to 'first' and 'rest' - are
 they a part of the language?

 Cons appears to be around.



 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: [ANN] Immutant 0.5.0 released

2012-10-16 Thread Michael Klishin
2012/10/16 Toby Crawley t...@tcrawley.org

 * We expose the Quartz job schedulers for each app, allowing you to use
 Quartzite instead of the Immutant job api,
  while still taking advantage of singleton jobs within a cluster


Nice, thank you!

-- 
MK

http://github.com/michaelklishin
http://twitter.com/michaelklishin

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

ClojureScript: how to call a js method when you have the method-string?

2012-10-16 Thread Frank Siebenlist
I understand that you can call js-methods and get properties thru:

(.a-method some-js-object param)

and 

(.-a-prop some-js-object)

respectively, but how do you invoke either when you have the method/property as 
a string?

The following doesn't seem to work:

(let [m a-method
  dot-m (symbol (str . m)]
  (dot-m some-js-object))

or

(let [m a-prop
  dot--m (symbol (str .- m)]
  (dot--m some-js-object))

And I cannot find any simple function interface for this.

I must be overlooking something - please…

Thanks, FrankS.


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: AOT-compilation, record types and DynamicClassLoader

2012-10-16 Thread Kevin Downey
have you cleaned out the classes/ directory recently? AOT'ing,
deftypes/defrecords, and lein when combined can exhibit issues with
stale generate classes for deftypes/defrecords. I would also try
adding (:gen-class) to your ns form. AOT compilation is effectively a
nop for the namespace without it, except for any
deftypes/records/protocols in the namespace, so a possible place for
those to get out of sync with the rest of the code.

DynamicClassloader generally means some compilation (code generation)
has happened, if a namespace has been AOT'ed the generate classes will
be loaded and the DynamicClassloader isn't required.

On Tue, Oct 16, 2012 at 2:17 PM, Chris Jeris cje...@brightcove.com wrote:
 I have a problem where I am trying to do an isa? or instance? check on an
 object of a record type which is defined in an AOT-compiled namespace.  The
 isa? check fails because -- under circumstances which I do not yet well
 understand -- the object I actually have is an instance of its class in a
 clojure.lang.DynamicClassLoader, whereas a reference to the class by its
 literal name yields the class in the base sun.misc.Launcher$AppClassLoader.

 My Clojure code is compiled into a jar which is included into a Jetty server
 whose app code is largely written in Java.  Here is an example which
 illustrates the problem:

 ;; src/foo/core.clj
 (ns foo.core)
 (defrecord T [a b])

 ;; project.clj
 (defproject foo 1.0.0-SNAPSHOT
   :dependencies [[org.clojure/clojure 1.4.0]]
   :aot [foo.core])

 Now if I add the artifact foo/foo as a Maven dependency of the Jetty server,
 and attach a liverepl to the running server (without taking any action to
 call the Clojure code from Java), I see the following:

 Clojure 1.4.0
 user= (require '[foo.core])
 nil
 user= (.getClassLoader foo.core.T)
 #AppClassLoader sun.misc.Launcher$AppClassLoader@a6eb38a
 user= (.getClassLoader (type (foo.core.T. 1 2)))
 #AppClassLoader sun.misc.Launcher$AppClassLoader@a6eb38a
 user= (.getClassLoader (type (foo.core/-T 1 2)))
 #DynamicClassLoader clojure.lang.DynamicClassLoader@433d3253

 My actual case is more complicated, but the principle is the same: instances
 of foo.core.T which were built by the defrecord constructor function -T do
 not inhabit the AppClassLoader version of the class, but rather a
 DynamicClassLoader version.  The result is that instance? or instanceof
 checks -- whether in my own Clojure code or in that of Java clients of my
 library who are trying to downcast -- do not behave as expected.

 This example cannot be reduced too far:  if one just builds an uberjar and
 invokes a repl on the Clojure library alone, using 'java -cp
 target/foo-1.0.0-SNAPSHOT-standalone.jar clojure.main', the result is
 different:

 Clojure 1.4.0
 user= (require '[foo.core])
 nil
 user= (.getClassLoader foo.core.T)
 #AppClassLoader sun.misc.Launcher$AppClassLoader@43be2d65
 user= (.getClassLoader (type (foo.core.T. 1 2)))
 #AppClassLoader sun.misc.Launcher$AppClassLoader@43be2d65
 user= (.getClassLoader (type (foo.core/-T 1 2)))
 #AppClassLoader sun.misc.Launcher$AppClassLoader@43be2d65

 Unfortunately I don't understand enough about the Clojure class loading
 mechanism to understand what might be causing the DynamicClassLoader to be
 invoked in one case and not the other.

 This problem seems to have been described by Ryan Senior about 20 months ago
 on clojure-dev, but I do not find any follow-up posts:
 https://groups.google.com/forum/?fromgroups=#!topic/clojure-dev/VBJFMEFBeFY

 Can anyone shed light on the situation?

 thanks, Chris Jeris
 --
 Chris Jeris
 cje...@brightcove.com (617) 686-3271
 freenode/twitter/github: ystael

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
And what is good, Phaedrus,
And what is not good—
Need we ask anyone to tell us these things?

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Clojure turns 5

2012-10-16 Thread Rich Hickey
I released Clojure 5 years ago today. It's been a terrific ride so far.

Thanks to everyone who contributes to making Clojure, and its community, great.

Rich

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Clojure turns 5

2012-10-16 Thread David Jagoe
Happy Birthday Clojure.

And thanks Rich!

On 16 October 2012 18:54, Rich Hickey richhic...@gmail.com wrote:
 I released Clojure 5 years ago today. It's been a terrific ride so far.

 Thanks to everyone who contributes to making Clojure, and its community, 
 great.

 Rich

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
David Jagoe

davidja...@gmail.com
+18053284389

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Clojure turns 5

2012-10-16 Thread Baishampayan Ghose
That's huge! Time flies. Happy Birthday Clojure and thank you very
much Rich for creating Clojure and fostering this amazing community.

Regards,
BG

On Tue, Oct 16, 2012 at 6:54 PM, Rich Hickey richhic...@gmail.com wrote:
 I released Clojure 5 years ago today. It's been a terrific ride so far.

 Thanks to everyone who contributes to making Clojure, and its community, 
 great.

 Rich

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en



-- 
Baishampayan Ghose
b.ghose at gmail.com

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Clojure turns 5

2012-10-16 Thread Joseph Smith
Whoo hoo!! Party!!!

Thanks to everyone, especially Rich, for creating and contributing to Clojure. 
:)

---
Joseph Smith
j...@uwcreations.com
@solussd


On Oct 16, 2012, at 8:54 PM, Rich Hickey richhic...@gmail.com wrote:

 I released Clojure 5 years ago today. It's been a terrific ride so far.
 
 Thanks to everyone who contributes to making Clojure, and its community, 
 great.
 
 Rich
 
 -- 
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Clojure turns 5

2012-10-16 Thread XPherior
Thanks to everyone. This community is transforming software engineering in 
a great way.

On Tuesday, October 16, 2012 10:01:29 PM UTC-4, solussd wrote:

 Whoo hoo!! Party!!! 

 Thanks to everyone, especially Rich, for creating and contributing to 
 Clojure. :) 

 --- 
 Joseph Smith 
 j...@uwcreations.com javascript: 
 @solussd 


 On Oct 16, 2012, at 8:54 PM, Rich Hickey richh...@gmail.com javascript: 
 wrote: 

  I released Clojure 5 years ago today. It's been a terrific ride so far. 
  
  Thanks to everyone who contributes to making Clojure, and its community, 
 great. 
  
  Rich 
  
  -- 
  You received this message because you are subscribed to the Google 
  Groups Clojure group. 
  To post to this group, send email to clo...@googlegroups.comjavascript: 
  Note that posts from new members are moderated - please be patient with 
 your first post. 
  To unsubscribe from this group, send email to 
  clojure+u...@googlegroups.com javascript: 
  For more options, visit this group at 
  http://groups.google.com/group/clojure?hl=en 


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Clojure turns 5

2012-10-16 Thread Paul Mooser
Thank you for clojure. 

Using clojure has exposed me to new ideas and made be a better programmer. 
I consider myself lucky to be able to use it every day at work. 

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Clojure turns 5

2012-10-16 Thread Softaddicts
Congratulations Rich,

http://3.bp.blogspot.com/_F0yEiHzEaRc/S1NUOQ1kNeI/C14/cAUqKY8nISk/s1600-h/HappyBdayFiveCandles.jpg

You can try to blow the candles :)

Happy birthday !

Luc

 I released Clojure 5 years ago today. It's been a terrific ride so far.
 
 Thanks to everyone who contributes to making Clojure, and its community, 
 great.
 
 Rich
 
 -- 
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en
 
--
Softaddictslprefonta...@softaddicts.ca sent by ibisMail from my ipad!

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Clojure turns 5

2012-10-16 Thread David Nolen
Congrats!

On Tuesday, October 16, 2012, Rich Hickey wrote:

 I released Clojure 5 years ago today. It's been a terrific ride so far.

 Thanks to everyone who contributes to making Clojure, and its community,
 great.

 Rich

 --
 You received this message because you are subscribed to the Google
 Groups Clojure group.
 To post to this group, send email to clojure@googlegroups.comjavascript:;
 Note that posts from new members are moderated - please be patient with
 your first post.
 To unsubscribe from this group, send email to
 clojure+unsubscr...@googlegroups.com javascript:;
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Rouge: Ruby + Clojure

2012-10-16 Thread Brian Marick

On Oct 16, 2012, at 1:19 PM, Arlen Cuss wrote:
 My initial solution is to freeze all strings in the reader.  This prevents 
 the most obvious issues, as it means any string read in from the Rouge code 
 itself is immutable.

A problem with `freeze` in Ruby is that it both prevents changing the contents 
of an object and also the methods attached to it. I find it useful sometimes to 
take an immutable object and create a new object with a different 
interpretation:

 hash.become(TimesliceShaped)

What that does is produce an object with some new singleton methods. That lets 
me do something like Clojure's `-` or the common Ruby boxcar notation:

 timeslice.transform.update

It makes the code more readable.

This is also vaguely analogous to multimethods. The point is that we want the 
functions applicable to an object to be mutable but the contents of the object 
to be immutable.


-
Brian Marick, Artisanal Labrador
Contract programming in Ruby and Clojure
Occasional consulting on Agile
Writing /Functional Programming for the Object-Oriented Programmer/: 
https://leanpub.com/fp-oo


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: ClojureScript: how to call a js method when you have the method-string?

2012-10-16 Thread Evan Mezeske
I think the easiest solution is to use aget and aset.  There may be a 
better way, but if so I'm not aware of it.

http://stackoverflow.com/questions/9861485/clojurescript-interop

On Tuesday, October 16, 2012 6:21:45 PM UTC-7, FrankS wrote:

 I understand that you can call js-methods and get properties thru: 

 (.a-method some-js-object param) 

 and 

 (.-a-prop some-js-object) 

 respectively, but how do you invoke either when you have the 
 method/property as a string? 

 The following doesn't seem to work: 

 (let [m a-method 
   dot-m (symbol (str . m)] 
   (dot-m some-js-object)) 

 or 

 (let [m a-prop 
   dot--m (symbol (str .- m)] 
   (dot--m some-js-object)) 

 And I cannot find any simple function interface for this. 

 I must be overlooking something - please… 

 Thanks, FrankS. 




-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: ClojureScript: how to call a js method when you have the method-string?

2012-10-16 Thread Frank Siebenlist
Thanks - that works - that was too easy ;-)

I looked at the docstring before of aget because I remembered vaguely that that 
was how it used to work before .- :

cljs.core/aget   -   Function

([array i] [array i  idxs])
  Returns the value at the index.

Dismissed it for object-access after reading that… guess we can improve on the 
clarity of the docstring a little.

-FS.


On Oct 16, 2012, at 8:20 PM, Evan Mezeske emeze...@gmail.com wrote:

 I think the easiest solution is to use aget and aset.  There may be a 
 better way, but if so I'm not aware of it.
 
 http://stackoverflow.com/questions/9861485/clojurescript-interop
 
 On Tuesday, October 16, 2012 6:21:45 PM UTC-7, FrankS wrote:
 I understand that you can call js-methods and get properties thru: 
 
 (.a-method some-js-object param) 
 
 and 
 
 (.-a-prop some-js-object) 
 
 respectively, but how do you invoke either when you have the method/property 
 as a string? 
 
 The following doesn't seem to work: 
 
 (let [m a-method 
   dot-m (symbol (str . m)] 
   (dot-m some-js-object)) 
 
 or 
 
 (let [m a-prop 
   dot--m (symbol (str .- m)] 
   (dot--m some-js-object)) 
 
 And I cannot find any simple function interface for this. 
 
 I must be overlooking something - please… 
 
 Thanks, FrankS. 
 
 

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: ClojureScript: how to call a js method when you have the method-string?

2012-10-16 Thread Evan Mezeske
Hmm after reading that docstring, /me hopes he didn't just recommend 
something for its not-intended purpose  :)

On Tuesday, October 16, 2012 8:29:47 PM UTC-7, FrankS wrote:

 Thanks - that works - that was too easy ;-) 

 I looked at the docstring before of aget because I remembered vaguely that 
 that was how it used to work before .- : 

 cljs.core/aget   -   Function 

 ([array i] [array i  idxs]) 
   Returns the value at the index. 

 Dismissed it for object-access after reading that… guess we can improve on 
 the clarity of the docstring a little. 

 -FS. 


 On Oct 16, 2012, at 8:20 PM, Evan Mezeske emez...@gmail.com javascript: 
 wrote: 

  I think the easiest solution is to use aget and aset.  There may be 
 a better way, but if so I'm not aware of it. 
  
  http://stackoverflow.com/questions/9861485/clojurescript-interop 
  
  On Tuesday, October 16, 2012 6:21:45 PM UTC-7, FrankS wrote: 
  I understand that you can call js-methods and get properties thru: 
  
  (.a-method some-js-object param) 
  
  and 
  
  (.-a-prop some-js-object) 
  
  respectively, but how do you invoke either when you have the 
 method/property as a string? 
  
  The following doesn't seem to work: 
  
  (let [m a-method 
dot-m (symbol (str . m)] 
(dot-m some-js-object)) 
  
  or 
  
  (let [m a-prop 
dot--m (symbol (str .- m)] 
(dot--m some-js-object)) 
  
  And I cannot find any simple function interface for this. 
  
  I must be overlooking something - please… 
  
  Thanks, FrankS. 
  
  



-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: ClojureScript: how to call a js method when you have the method-string?

2012-10-16 Thread Frank Siebenlist
Looking at the source of cljs.core/js-clj,
I see that aget is also used to access the object properties by name-string…

So please tell /me not to worry ;-)

-FS. 



On Oct 16, 2012, at 8:30 PM, Evan Mezeske emeze...@gmail.com wrote:

 Hmm after reading that docstring, /me hopes he didn't just recommend 
 something for its not-intended purpose  :)
 
 On Tuesday, October 16, 2012 8:29:47 PM UTC-7, FrankS wrote:
 Thanks - that works - that was too easy ;-) 
 
 I looked at the docstring before of aget because I remembered vaguely that 
 that was how it used to work before .- : 
 
 cljs.core/aget   -   Function 
 
 ([array i] [array i  idxs]) 
   Returns the value at the index. 
 
 Dismissed it for object-access after reading that… guess we can improve on 
 the clarity of the docstring a little. 
 
 -FS. 
 
 
 On Oct 16, 2012, at 8:20 PM, Evan Mezeske emez...@gmail.com wrote: 
 
  I think the easiest solution is to use aget and aset.  There may be a 
  better way, but if so I'm not aware of it. 
  
  http://stackoverflow.com/questions/9861485/clojurescript-interop 
  
  On Tuesday, October 16, 2012 6:21:45 PM UTC-7, FrankS wrote: 
  I understand that you can call js-methods and get properties thru: 
  
  (.a-method some-js-object param) 
  
  and 
  
  (.-a-prop some-js-object) 
  
  respectively, but how do you invoke either when you have the 
  method/property as a string? 
  
  The following doesn't seem to work: 
  
  (let [m a-method 
dot-m (symbol (str . m)] 
(dot-m some-js-object)) 
  
  or 
  
  (let [m a-prop 
dot--m (symbol (str .- m)] 
(dot--m some-js-object)) 
  
  And I cannot find any simple function interface for this. 
  
  I must be overlooking something - please… 
  
  Thanks, FrankS. 
  
  
 

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Clojure turns 5

2012-10-16 Thread kovas boguta
Congrats!

The output coming out of Rich and Clojure/core lately is coming at an
unbelievable pace. Keep up the good work :)


On Tue, Oct 16, 2012 at 11:15 PM, David Nolen dnolen.li...@gmail.com wrote:
 Congrats!


 On Tuesday, October 16, 2012, Rich Hickey wrote:

 I released Clojure 5 years ago today. It's been a terrific ride so far.

 Thanks to everyone who contributes to making Clojure, and its community,
 great.

 Rich

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Remembering locations in a zipper

2012-10-16 Thread Timothy Baldridge
I have a zipper and here's the code I'm trying to execute:

1) search through all nodes until a match for a predicate is found
2) starting at that node go up to its parent then mark all children of the
parent with extra info
3) the parent has the option to go to it's parent and perform step 2 as well
4) go back to the node marked in (1) and continue execution, but with the
latest version of the zipper as defined by (2) and (3)

Since zippers use immutable data I can't simply go back to the data in 1 as
then I'll loose my changes. Is there currently some way to save the path to
the current node and then later reset to root and replay the
zipper commands to get back to that node?

Thanks,

Timothy

-- 
“One of the main causes of the fall of the Roman Empire was that–lacking
zero–they had no way to indicate successful termination of their C
programs.”
(Robert Firth)

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Rouge: Ruby + Clojure

2012-10-16 Thread Arlen Cuss
On Wednesday, 17 October 2012 at 4:11 AM, Phil Hagelberg wrote:
 http://home.pipeline.com/~hbaker1/ObjectIdentity.html

Thanks for the link, too—I'm working through it with interest.

As for mutability in Rouge, I had another thought—freezing (or possibly duping 
then freezing) Ruby String objects when returned by the core evaluator would 
probably do the trick comprehensively; it would incur a performance penalty, 
but it would be at least starting on the right foot.

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: ANN: Clojure 1.3 and 1.4 Cheat Sheet v7

2012-10-16 Thread Nick Klauer
Other than the PDF being colorful, no. :)  

It does make a beautiful setting on my wall next to my computer, though.

-Nick

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Clojure turns 5

2012-10-16 Thread AtKaaZ
That's *a lot* of hard work. I am amazed of how much work goes into making
such great software with the studying and the many years spent training
yourself(generally speaking, not just Rich, but certainly I myself am not
part of that list) before the project even started. Sometimes it just
boggles my mind realizing how impossible it would've been for me to do
that  coupled with the amount of work and prerequisites that the body/mind
required to have had to do it.

Clojure is much appreciated! Thank you all for all the hard work making
this possible.

On Wed, Oct 17, 2012 at 3:54 AM, Rich Hickey richhic...@gmail.com wrote:

 I released Clojure 5 years ago today. It's been a terrific ride so far.

 Thanks to everyone who contributes to making Clojure, and its community,
 great.

 Rich

 --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en




-- 
I may be wrong or incomplete.
Please express any corrections / additions,
they are encouraged and appreciated.
At least one entity is bound to be transformed if you do ;)

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Inconsistent Exceptions

2012-10-16 Thread AtKaaZ
Compile compliance level: 1.6
Generated class files compatibility: 1.6
Source compatibility: 1.6

I think regardless of what jdk you use to run/compile them, these 3 (or at
least the first 2) are affecting what you said. I got those from eclipse
(but there should be command line equivalents of those: ie. in project.clj
with leiningen
*:javac-options [-target 1.6 -source 1.6 -Xlint:-options
-g:source,lines -encoding utf8]*
, I pasted the entire line, but only -target and -source are relevant)

I think the usual errors when one project uses 1.7 (for the first 2) and
the other uses like 1.6, is like:
*java.lang.UnsupportedClassVersionError: Unsupported major.minor version*51.0
(where the number may differ)

In eclipse, all 3 must be the same else it will not allow it, i see.

Anyway, that's my 2 cents about it:) I may be wrong, corrections/additions
are welcome.

On Tue, Oct 16, 2012 at 1:27 AM, JvJ kfjwhee...@gmail.com wrote:

 I just found out that my clojure project is using jre7, while the other
 project is using jre6.  That probably has something to do with it.

 In other words, you were right. In eclipse, by default, changing the jdk
used changes all 3 of those automatically by default (unless you have
Enable project specific settings for the Java Compiler section in project
properties - but if you're using leiningen to uberjar this has no effect
obviously, it's the above in project.clj you'd want)



 On Monday, 15 October 2012 19:17:26 UTC-4, JvJ wrote:

 I'm having a peculiar issue with Java interop.

 I'm running a program in 2 different ways:
 -Running the program directly
 -Calling the main function from Clojure

 Oddly, by calling main from Clojure, I get an exception that isn't there
 when I run normally:
 UnsupportedOperationException This parser does not support specification
 null version null  javax.xml.parsers.**SAXParserFactory.setSchema
 (:-1)

 I was able to use the debugger using both running methods, and the
 parameters seem to be the same.  I just don't get it.  Does anyone have any
 ideas?

  --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Clojure turns 5

2012-10-16 Thread Robert Luo
It was an incredible language, five years with clojure is an incredible 
journey, helping me understand programming better, and do programming 
better. Thanks Rich!

On Wednesday, October 17, 2012 9:53:55 AM UTC+8, Rich Hickey wrote:

 I released Clojure 5 years ago today. It's been a terrific ride so far. 

 Thanks to everyone who contributes to making Clojure, and its community, 
 great. 

 Rich

-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: ClojureScript: how to call a js method when you have the method-string?

2012-10-16 Thread David Nolen
It may be worth considering adding an oget to complement aget as was
suggesting during ClojureScript/Lua development.

David

On Tue, Oct 16, 2012 at 11:30 PM, Evan Mezeske emeze...@gmail.com wrote:

 Hmm after reading that docstring, /me hopes he didn't just recommend
 something for its not-intended purpose  :)


 On Tuesday, October 16, 2012 8:29:47 PM UTC-7, FrankS wrote:

 Thanks - that works - that was too easy ;-)

 I looked at the docstring before of aget because I remembered vaguely
 that that was how it used to work before .- :

 cljs.core/aget   -   Function

 ([array i] [array i  idxs])
   Returns the value at the index.

 Dismissed it for object-access after reading that… guess we can improve
 on the clarity of the docstring a little.

 -FS.


 On Oct 16, 2012, at 8:20 PM, Evan Mezeske emez...@gmail.com wrote:

  I think the easiest solution is to use aget and aset.  There may be
 a better way, but if so I'm not aware of it.
 
  http://stackoverflow.com/**questions/9861485/**clojurescript-interophttp://stackoverflow.com/questions/9861485/clojurescript-interop
 
  On Tuesday, October 16, 2012 6:21:45 PM UTC-7, FrankS wrote:
  I understand that you can call js-methods and get properties thru:
 
  (.a-method some-js-object param)
 
  and
 
  (.-a-prop some-js-object)
 
  respectively, but how do you invoke either when you have the
 method/property as a string?
 
  The following doesn't seem to work:
 
  (let [m a-method
dot-m (symbol (str . m)]
(dot-m some-js-object))
 
  or
 
  (let [m a-prop
dot--m (symbol (str .- m)]
(dot--m some-js-object))
 
  And I cannot find any simple function interface for this.
 
  I must be overlooking something - please…
 
  Thanks, FrankS.
 
 

  --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Clojure turns 5

2012-10-16 Thread Alex Baranosky
Clojure is the gift that keep giving.  I, for one, really appreciate what
you've done Rich, and can't wait to work with it more and take part in the
community as it grows.

Alex

On Tue, Oct 16, 2012 at 9:39 PM, Robert Luo l...@basecity.com wrote:

 It was an incredible language, five years with clojure is an incredible
 journey, helping me understand programming better, and do programming
 better. Thanks Rich!


 On Wednesday, October 17, 2012 9:53:55 AM UTC+8, Rich Hickey wrote:

 I released Clojure 5 years ago today. It's been a terrific ride so far.

 Thanks to everyone who contributes to making Clojure, and its community,
 great.

 Rich

  --
 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
 clojure+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/clojure?hl=en


-- 
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
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en