Re: Literate programming in emacs - any experience?

2012-01-24 Thread Colin Yates
The topic is literate programming in emacs, not eclipse ;). The trivial amount of Clojure I have done so far has all been in emacs and letting go of paredit, slime, and emacs in general is already pretty hard! On 24 January 2012 03:06, daly d...@axiom-developer.org wrote: For Eclipse I

Re: Logic program and hierarchical data

2012-01-24 Thread Base
Thank you all! David, as always, greatly appreciated! On Jan 23, 11:09 pm, David Nolen dnolen.li...@gmail.com wrote: On Tue, Jan 24, 2012 at 12:00 AM, Cedric Greevey cgree...@gmail.com wrote: On Mon, Jan 23, 2012 at 11:41 PM, David Nolen dnolen.li...@gmail.com wrote: (def homo-sapiens

Re: ANN: Clojure/West conf and training early bird ends this Friday

2012-01-24 Thread Alex Miller
Below is an updated title and abstract for Richard Gabriel's (http:// dreamsongs.com/) keynote at Clojure/West: Title: Engineering(,) A Path to Science: “I don’t want to die in a language I can’t understand Abstract: I’m going to talk about one, old paper: “Mixin-based Inheritance,” by Gilad

Re: Logic program and hierarchical data

2012-01-24 Thread Ryan Senior
I think separating the facts from determining the hierarchy makes it easier: (defrel typeof* p c) (facts typeof* [[:homo :homo-sapiens] [:hominidae :homo] [:primate :hominidae] [:mammalia :primate] [:chordata :mammalia]

Re: How to loop over several sequences in parallel for side-effects?

2012-01-24 Thread joachim
First: Thanks all for your thoughts. Second: I have the same question as Allen (why would the doseq variant be faster in this case?) Finally: so I guess that what I did was also OK then? Jm On Jan 20, 9:57 pm, Alan Malloy a...@malloys.org wrote: But I don't see any reason why this would be

How to add a new type of collection?

2012-01-24 Thread joachim
Dear, I am using a java class that implements sparse matrices (see http://javasourcecode.org/html/open-source/mahout/mahout-0.5/org/apache/mahout/math/SparseMatrix.html). I was wondering how to add them to clojure as a new type of collection, so that I can use nth and count etc. on them? Thanks,

Re: Clojure for Cocoa

2012-01-24 Thread Axel Katerbau, Objectpark
Hi Konrad, On 23 Jan., 05:13, Konrad Hinsen googlegro...@khinsen.fastmail.net wrote: David Nolen writes:   Having a version of Clojure that integrates with OS X as well as Clojure   integrates with the JVM will be a much more ambitious task but it would be   really, really cool. As this

Re: Clojure for Cocoa

2012-01-24 Thread Axel Katerbau, Objectpark
Hi David, On 23 Jan., 04:00, David Nolen dnolen.li...@gmail.com wrote: This would be cool. I think just comes down to how ambitious you are. ClojureScript is effectively Clojure-in-Clojure. Given that we can target JavaScript communicating with Objective-C is not that difficult, i.e.

Re: Concurrency Talk materials

2012-01-24 Thread Sergey Stupin
This link http://clojure.googlegroups.com/web/ClojureConcurrencyTalk.pdf is broken. Where can i get slides? Thank you. -- 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

Re: Literate programming in emacs - any experience?

2012-01-24 Thread Stuart Sierra
With a little hacking, org-babel works with Clojure editing evaluation in SLIME. I've been using it to write Clojure training materials. You need the latest versions of org-mode, SLIME, and clojure-mode. My .emacs has the relevant elisp snippets. http://github.com/stuartsierra/dotfiles -S

Re: How to add a new type of collection?

2012-01-24 Thread Stuart Sierra
The fundamental interfaces are all written in Java. ISeq, IPersistentCollection, and so on. You can implement then in deftype. Look at (ancestors (class [])) as a place to start. -S -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this

Re: Literate programming in emacs - any experience?

2012-01-24 Thread Colin Yates
Thanks Stuart. On 24 January 2012 14:18, Stuart Sierra the.stuart.sie...@gmail.com wrote: With a little hacking, org-babel works with Clojure editing evaluation in SLIME. I've been using it to write Clojure training materials. You need the latest versions of org-mode, SLIME, and

Re: Concurrency Talk materials

2012-01-24 Thread Kevin Ilchmann Jørgensen
https://encrypted.google.com/search?hl=enq=ClojureConcurrencyTalk.pdf Gives me ftp://ftp.elet.polimi.it/users/Matteo.Giovanni.Rossi/Didattica/FunProgLang4Parallelism/04-ClojureConcurrencyTalk.pdf Is that it ? /Kevin On Mon, Jan 23, 2012 at 6:14 AM, Sergey Stupin stupin.ser...@gmail.com

Re: Clojure for Cocoa

2012-01-24 Thread Timothy Baldridge
Clojure in Clojure would be a nice start to have e.g. a LLVM frontend. But it's really quiet as far as CiC goes, right? It should be mentioned that writing a Clojure compiler is not a very long task it basically comes down to the following tasks: 1) Implement the persistent classes

Re: Clojure for Cocoa

2012-01-24 Thread David Nolen
On Mon, Jan 23, 2012 at 4:55 AM, Axel Katerbau, Objectpark akater...@googlemail.com wrote: Hi David, On 23 Jan., 04:00, David Nolen dnolen.li...@gmail.com wrote: This would be cool. I think just comes down to how ambitious you are. ClojureScript is effectively Clojure-in-Clojure. Given

Re: How to loop over several sequences in parallel for side-effects?

2012-01-24 Thread Armando Blancas
Well, you can always use the (time) macro and pick what runs faster: (dorun (map some-fn-with-side-effects sequence-1 sequence-2)) (doseq [x (map some-fn-with-side-effects sequence-1 sequence-2))]) (doseq) could be faster in some cases because its implementation uses chunked sequences. Now,

How to use goog.dom.query

2012-01-24 Thread Jonas
Hi all I was wondering if it's possible to use goog.dom.query[1] from ClojureScript or ClojureScript One? It's a third party module but it's bundled with the Closure version which is downloaded by scripts/bootstrap. I've tried (:require [goog.dom.query :as query]) but that doesn't work out of

Re: How to use goog.dom.query

2012-01-24 Thread Mark Rathwell
You can look at how Pinot does it, some links to get you started: https://github.com/ibdknox/pinot https://github.com/ibdknox/pinot/blob/master/project.clj https://github.com/ibdknox/pinot/blob/master/src/pinot/dom.cljs https://groups.google.com/forum/#!msg/clj-noir/x5x9vcI-T4E/FaCfb8jhDXoJ On

Re: How to use goog.dom.query

2012-01-24 Thread Dave Sann
The third party libs are not included in the std closurescript jar. pinot requires a modified jar that contains the extra libs. If you follow the instructions for pinot - you can get this lib and install it - it's fairly painless. I don't know of an easy way to include these without doing

Help coding Eller's maze algorithm.

2012-01-24 Thread Gabriele Carrettoni
Hi, I'm trying to code the algorithm described herehttp://weblog.jamisbuck.org/2010/12/29/maze-generation-eller-s-algorithm with no luck. I'm struggling to find the best data structure to hold each cell, how to random join cells and how to build the next row. I'm not necessarily looking for

Conflicting transactions

2012-01-24 Thread Ersin Er
Hi, What does conflicting transactions actually mean in terms of Clojure STM? Are they write-write transactions on a data structure or are they more granularly considered conflicting for example if they are manipulating the same element of a target data structure (e.g. HashMap)? Thanks. --

Re: How to use goog.dom.query

2012-01-24 Thread Dave Sann
when I say clojurescript jar here - I meant specifically the goog.jar found in the lib dir of your clojurescript install. This contains the closure libraries. -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to

Re: How to add a new type of collection?

2012-01-24 Thread Ben Mabey
On 1/24/12 7:20 AM, Stuart Sierra wrote: The fundamental interfaces are all written in Java. ISeq, IPersistentCollection, and so on. You can implement then in deftype. Look at (ancestors (class [])) as a place to start. -S I believe the OP wanted to know if they could extend a java data

Adding primitive type hints to anonymous functions

2012-01-24 Thread Ben Mabey
Does the new primitive support added in 1.3 extend to anonymous functions? If so, I am doing something wrong because I can't get them to work: (definterface IPrimitiveTester (getType [^int x]) (getType [^long x]) (getType [^float x]) (getType [^double x]) (getType [^Object x]))

Re: Conflicting transactions

2012-01-24 Thread Kevin Downey
On Tue, Jan 24, 2012 at 8:49 AM, Ersin Er ersin...@gmail.com wrote: Hi, What does conflicting transactions actually mean in terms of Clojure STM? Are they write-write transactions on a data structure or are they more granularly considered conflicting for example if they are manipulating the

Re: How to add a new type of collection?

2012-01-24 Thread Stuart Sierra
Oh, I see. Yes, you can't do that in Clojure right now, because the core functions are not based on Protocols. ClojureScript is built on Protocols from the ground up. It would be nice to have this in Clojure too, but would require some pretty serious redesign. -S -- You received this message

Re: How to add a new type of collection?

2012-01-24 Thread endbegin
I know this isn't exactly what the OP is looking for, but the Incanter project has done something for dense matrices that might work. The Matrix type has been imported (which is a java class), and a whole bunch of functions have been implemented on that class. See here

Re: Adding primitive type hints to anonymous functions

2012-01-24 Thread Tassilo Horn
Ben Mabey b...@benmabey.com writes: Hi Ben, Does the new primitive support added in 1.3 extend to anonymous functions? I guess, it should. At least they are not disregarded... --8---cut here---start-8--- user (def with-def (fn ^float [^float x]