I am putting together a framework that relies on bidirectional
references, but am seeing problems in displaying the results. The
default string output of a reference includes the referenced value,
but if that refers back to the original reference you end up with an
infinite loop and a stack overf
Craig McDaniel writes:
> Correction:
>
> (defun reset-swank ()
>
> (defun run-slime (dir)
Here's what I use: (plagiarized from Tim Dysinger)
(defun slime-project (path)
"Setup classpaths for a maven/clojure project & refresh slime"
(interactive "GPath: ")
(let ((original-dir default-dir)
On Mon, Apr 20, 2009 at 5:17 PM, Hugh Winkler wrote
>
>
> Thanks! I think 'nth ought to behave just like 'first and 'second,
> don't you? If it's a good idea for 'first it's a good idea for 'nth.
>
It does seems like a reasonable behavior for sorted-set and sorted-map, but
what else really? Also
Correction:
(defun reset-swank ()
"Because changing swank-clojure-extra-classpaths is not enough
to force a new instance of slime to use it."
(interactive)
(setq slime-lisp-implementations
(assq-delete-all 'clojure slime-lisp-implementations))
(add-to-list 'slime-lisp-implementati
Ah, that'll do the trick! Thank you so much, Laurent. I should have
been able to figure that one out myself... Oh well!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Clojure" group.
To post to this group, send emai
Hi,
try
(defmacro req-> [[state msg] & body]
`(defmethod ~'do-request [Foo ~state ~msg]
[~'arg1 ~'arg2 ~(quote #^String arg3)]
~...@body))
HTH,
laurent
2009/4/21 Richard Newman :
>
> Hi folks,
>
> I'm attempting to define methods within the output of a macro. As
> these are definitio
Hi folks,
I'm attempting to define methods within the output of a macro. As
these are definitions for syntactic benefit more than anything else,
I'm using the unquote-quote trick for argument names, so that the
input body can refer anaphorically to known names (like "request").
Convention over co
On Apr 21, 11:41 am, Mark Engelberg wrote:
> On Mon, Apr 20, 2009 at 11:00 AM, Timo Mihaljov wrote:
> > Is the concept of Abstract Data Types [1] useful in Clojure?
>
> > If yes, how would you implement one?
>
> I have composed a lengthy response to this question, and added it to my
> blog:http
On Apr 20, 9:13 am, Sean Devlin wrote:
> http://www.sun.com/third-party/global/oracle/index.jsp
>
> Any thoughts on how this affects Clojure?
Ars Technica has a good analysis, and a fabulous graphic:
http://tinyurl.com/csyxos
quote: "Oracle is a prominent player in the Java middleware space and
2009/4/21 Daniel Jomphe :
>
> Laurent PETIT wrote:
>> > version: 1.0.0-rc1-SNAPSHOT
>> > yields: clojure-1.0.0-rc1-.jar
>> > (and ...-slim.jar, ...-sources.jar)
>>
>> There it is. But why having "" in the name of the jar,
>> shouldn't it just be "SNAPSHOT" (as far as I remember) ?
>>
Laurent PETIT wrote:
> > version: 1.0.0-rc1-SNAPSHOT
> > yields: clojure-1.0.0-rc1-.jar
> > (and ...-slim.jar, ...-sources.jar)
>
> There it is. But why having "" in the name of the jar,
> shouldn't it just be "SNAPSHOT" (as far as I remember) ?
>
> That is:
>
> { :major 1 :minor 0 :i
Hi,
2009/4/21 Daniel Jomphe :
>
> version: 1.0.0-rc1-SNAPSHOT
> yields: clojure-1.0.0-rc1-.jar
> (and ...-slim.jar, ...-sources.jar)
There it is. But why having "" in the name of the jar,
shouldn't it just be "SNAPSHOT" (as far as I remember) ?
That is:
{ :major 1 :minor 0 :increm
Well,
Once the API has defined correctly documented accessor functions, I
think that trying to protect the user from himself at any cost may
well be counter productive (in general, of course).
Indeed, by not just using regular datastructures anymore for
"essential state", you'll loose somehow th
Paul Stadig wrote:
> Others have commented on the whole groupId, artifactId, etc., etc. But in
> terms of the parts of the version number, they are named
> ..- as documented here:
>
> http://www.sonatype.com/books/maven-book/reference/pom-relationships-...
Thanks for the info.
So I was wrong in
Nice post thanks for putting it together. My gut feeling is that the need
for information hiding is still overinflated, but... until someone builds a
200k LOC Clojure program who will know for sure?
Here's my shot at a solution for private data:
(defn set-private [m k x]
(let [the-meta(meta
On Sat, Apr 18, 2009 at 5:34 AM, Isak Hansen wrote:
>
> On Thu, Apr 16, 2009 at 6:53 PM, Rich Hickey wrote:
>>
>> Feedback welcome,
>>
>
> 1. I'd like to see a road map of sorts; plans for where Clojure will
> be going with the next couple of releases.
>
> 2. Clojure-contrib -cleanup
> - Move t
On Apr 21, 1:16 am, Brian Doyle wrote:
> I posted this a couple of weeks ago and haven't seen it updated on the
> clojure
> website. Maybe it got lost in the shuffle.
>
I'd missed it - sorry. It's up now.
Thanks!
Rich
--~--~-~--~~~---~--~~
You received this
On Mon, Apr 20, 2009 at 8:52 PM, Rich Hickey wrote:
> On Apr 20, 2009, at 7:02 PM, Antony Blakey wrote:
> > On 21/04/2009, at 5:12 AM, Laurent PETIT wrote:
> >
> >> { :major 1 :minor 0 :release 0 :status :SNAPSHOT }
> >> then
> >> { :major 1 :minor 0 :release 0 :status :RC1 } (release candidate
Laurent PETIT wrote:
> I have not followed maven2 concerning this "qualifier" thing.
Right. The first (small) part of my post, which referred to yours, was
strictly about versioning, and specifically about the end of the
version string, related to snapshots.
Then I addressed the classifier as an
On Mon, 20 Apr 2009 21:53:41 +0200
Laurent PETIT wrote:
>
> Hi David,
>
> 2009/4/20 David Nolen :
> > A couple of things. In your initial example, you conflated some
> > things. One issue is simply a matter of convenience- defining a
> > getter so that you can use Python object property access
Thanks to *everyone* for responding! I can see that I was over
reacting yesterday. Time for me to stop worrying and get back to
coding.
Sean
On Apr 21, 2:05 am, Adrian Cuthbertson
wrote:
> There are some precedents - the acquisition of SleepyCat (berkeley db,
> et al) - still readily availabl
On Apr 20, 2009, at 12:19 PM, Michael Hunger wrote:
>
> Is it possible to use :while to shortcut a for macro when a certain
> number of yiels have happened?
>
> e.g. (for [x (range 1000) :when (= (rem x) 1) :while (number of
> yields <= 10)]
>
> so i want only the first 10 results.
Is it po
I am a newbie, but seems that "for comprehension" are lazy lists:
user> (take 5 (for [x (range 20) :when (do (printf "*%d* " x) (= (rem x 2)
1))] x))
(*0* *1* *2* *3* 1 *4* *5* 3 *6* *7* 5 *8* *9* 7 9)
So, I think that you should use take :)
2009/4/21 Michael Hunger
>
> Is it possible to use
On Mon, Apr 20, 2009 at 11:00 AM, Timo Mihaljov wrote:
> Is the concept of Abstract Data Types [1] useful in Clojure?
>
> If yes, how would you implement one?
I have composed a lengthy response to this question, and added it to my blog:
http://programming-puzzler.blogspot.com/2009/04/adts-in-clo
Hello,
(def lazy-identity [x] (lazy-seq x))
(nth (iterate lazy-identity [1 2]) 10) ; returns (1 2)
(nth (iterate lazy-identity [1 2]) 1000) ; returns (1 2)
(nth (iterate lazy-identity [1 2]) 10) ; (with my JVM settings)
throws a StackOverflowException
Each time that you are building a lazy
2009/4/21 AndrewC. :
>
> On Apr 21, 1:52 am, Rich Hickey wrote:
>
>>
>> I'm unfamiliar with the POM version coordinate system - any hints?
>>
>> Rich
>
> 1 Pager on coordinates from the 'definitive guide'
>
> http://www.sonatype.com/books/maven-book/reference/simple-project-sect-maven-coordinates
On Apr 21, 1:52 am, Rich Hickey wrote:
>
> I'm unfamiliar with the POM version coordinate system - any hints?
>
> Rich
1 Pager on coordinates from the 'definitive guide'
http://www.sonatype.com/books/maven-book/reference/simple-project-sect-maven-coordinates.html
--~--~-~--~~
Hi Jleehurt,
I'm still newbie and don't know, but you have at least two recursive
functions - matrixAdd, and matrixMultiplyScalar.
I've modified them to work with loop/recur, but I can't tell whether
they are with same efficiency (at least no stack problem).
Still if I remove the "dorun" from t
Hi Dimiter,
Thank you! I'm still a bit confused as to why this was happening. Does
lazy evaluation not work well with recursion?
On Apr 20, 11:06 pm, "Dimiter \"malkia\" Stanev"
wrote:
> I blindly tried printing out stuff from matrixMultiply, and found out
> that if I print matrixA and matrixB
29 matches
Mail list logo