Re: clojure.contrib.logging and Google App Engine

2010-04-26 Thread gary ng
On Mon, Apr 26, 2010 at 6:26 PM, gary ng wrote: > > > On Sun, Apr 25, 2010 at 4:47 PM, ataggart wrote: > >> Yeah, the fix-patch was submitted prior to the final release of 1.1.0, >> but alas none of those with the power to actually commit the patch got >> around to it until it was too late. >> >

ClassCastException using let

2010-04-26 Thread borgees
I'm a clojure newbie, trying to automate a script at work and running into an issue. Given a function (defn diffCommonOrders "For each order, checks the two execs maps for the entries and reports the differences" [orders1 orders2 execs1 execs2] (for [order (vals orders1) :when (not-empty

Re: Any window user familiar with clojure-contrib development ?

2010-04-26 Thread Armando Blancas
I build on Windows and it's fine most of the time. I didn't deal with (1) and (2) as my initial clone was OK; I avoid (3) with - Dmaven.test.skip=true But sometimes I get these errors even though I don't change any files. I work around this by deleting the files and repeating the pull. I don't kno

Re: clojure.contrib.logging and Google App Engine

2010-04-26 Thread gary ng
On Sun, Apr 25, 2010 at 4:47 PM, ataggart wrote: > Yeah, the fix-patch was submitted prior to the final release of 1.1.0, > but alas none of those with the power to actually commit the patch got > around to it until it was too late. > > I have built the 1.2.0-snapshot which seems to be even worse

Any window user familiar with clojure-contrib development ?

2010-04-26 Thread gary ng
Hi, I am wondering if there is any windows user who is familiar with clojure-contrib project. The reason I asked is that I encountered quite some issues when trying to build my own copy of clojure-contrib(on windows). That includes: 1. I cannot clone http://github.com/richhickey/clojure-contrib.

Re: tutorial on clojure protocols 1.2

2010-04-26 Thread Ryan Waters
>From the perspective of a clojure beginner, it was good information and I grokked almost everything. Specifically, any lack of comprehension on my part has more to do with the topic and my lack of clojure expertise than with your presentation. ; ) I wasn't aware of all the resources at the end

Re: tutorial on clojure protocols 1.2

2010-04-26 Thread DmitriKo
Yeah, Stuart, well done ! On Apr 26, 10:44 pm, Tim Harper wrote: > On Mon, Apr 26, 2010 at 10:20 AM, Stuart Halloway > > wrote: > > I have created a short (30 min) tutorial on clojure protocols at > >http://vimeo.com/11236603. Hope some of you will find it useful. > > > Feedback welcome! > > >

Re: Conflicting definition for IPersistentVector

2010-04-26 Thread Rich Hickey
On Apr 13, 2010, at 9:37 AM, Dan wrote: I'm a Java developer; I work on a project that has adopted Clojure's data structures as a convenient implementation of immutable sets, maps, etc. In attempting to add type parameters to the Clojure interfaces, I noticed a conflict in the definition of IP

Re: tutorial on clojure protocols 1.2

2010-04-26 Thread Tim Harper
On Mon, Apr 26, 2010 at 10:20 AM, Stuart Halloway wrote: > I have created a short (30 min) tutorial on clojure protocols at > http://vimeo.com/11236603. Hope some of you will find it useful. > > Feedback welcome! > > Stu > Watched it today during lunch, it was great! Thanks Stuart. -- You rece

Re: Conflicting definition for IPersistentVector

2010-04-26 Thread Dan
Bumping. Let me emphasize this paragraph, which is really the crux of the problem: > Put another way, the problem is that if I have an Associative which I > know maps integers to strings, and I invoke seq(), I don't know what > kind of values I'm going to get. Is this expected behavior or a bug?

tutorial on clojure protocols 1.2

2010-04-26 Thread Stuart Halloway
I have created a short (30 min) tutorial on clojure protocols at http://vimeo.com/11236603 . Hope some of you will find it useful. Feedback welcome! Stu -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@go

Re: Questions about program design

2010-04-26 Thread Andrew Brookins
On Mon, Apr 26, 2010 at 5:49 AM, Paul Drummond wrote: > Hi Andrew, > > It's getting old now but you mind find this helpful: > > http://groups.google.com/group/clojure/browse_thread/thread/6333791e49fbca7f/c724f1681dac3102?lnk=gst&q=drummond#c724f1681dac3102 > > and this: > > http://clojure.org/sta

Re: Questions about program design

2010-04-26 Thread Paul Drummond
Hi Andrew, It's getting old now but you mind find this helpful: http://groups.google.com/group/clojure/browse_thread/thread/6333791e49fbca7f/c724f1681dac3102?lnk=gst&q=drummond#c724f1681dac3102 and this: http://clojure.org/state Cheers, Paul Drummond On 25 April 2010 18:45, Andrew Brookins w

Re: Datatypes and Protocols update

2010-04-26 Thread Konrad Hinsen
On 24.04.2010, at 05:48, Mark Engelberg wrote: > As far as I know, Clojure doesn't currently make any attempt to > address this problem of allowing a standard way to access public data > from an object, while preserving the option of doing something more > sophisticated later. So a programmer is

Questions about program design

2010-04-26 Thread Andrew Brookins
Hey, all, Writing in a functional language and using a REPL for the first time, I feel like I'm playing with awesome magic. However, I'm a little confused. I have about two years of experience working with object-oriented scripting languages and C. I am somewhat familiar with thinking in terms

ClojureCLR multiple .dll files

2010-04-26 Thread lucidquiet
Hello, I'm using ClojureCLR, at the moment I've created a couple of files that each have a (ns .. :gen-class .. ) in them. I then compiled both clj and the result is a [name].clj.dll for each file. The question I have: is there a way to create just a single dll as a result of compilation. I'm a

Re: Datatypes and Protocols update

2010-04-26 Thread Rich Hickey
On Apr 24, 2010, at 1:11 PM, Richard Newman wrote: Neither of those attributes reveal information about the implementation of the objects in question. They both reveal information about the state that some client could find useful. They are both values that, if not directly available from the o

Re: Datatypes and Protocols update

2010-04-26 Thread Rich Hickey
On Apr 23, 2010, at 11:48 PM, Mark Engelberg wrote: A few meandering observations: I like the latest change to include a this argument. It makes the number of arguments line up which is a good thing. I like the idea of defrecord for the common case, rather than having to request default impl

Re: Laziness and deadlocks

2010-04-26 Thread Meikel Brandmeyer
Hi, On 26 Apr., 13:27, Per Vognsen wrote: > Okay, that is a blatant infinite loop that has nothing to do with > deadlocks. I give up. This combination of laziness and concurrency and > locking is giving me a headache. Sorry about the distraction, > everyone. Well, we can step through the code a

Re: TransactionalHashMap hash computation bug

2010-04-26 Thread Rich Hickey
On Apr 25, 2010, at 8:33 PM, John wrote: I got no response since I posted the previous message. Should I be posting bugs to assembla space instead of here ? Yes, please create an issue. Do I need to be a member to do that ? No, you can use the support tab if you are not a member. Note t

Re: Laziness and deadlocks

2010-04-26 Thread Per Vognsen
Okay, that is a blatant infinite loop that has nothing to do with deadlocks. I give up. This combination of laziness and concurrency and locking is giving me a headache. Sorry about the distraction, everyone. -Per On Mon, Apr 26, 2010 at 6:23 PM, Per Vognsen wrote: > On Mon, Apr 26, 2010 at 6:15

Re: Laziness and deadlocks

2010-04-26 Thread Per Vognsen
On Mon, Apr 26, 2010 at 6:15 PM, Per Vognsen wrote: > [...] > The idea is to try to create a situation where a pair of LazySeqs, xs > and ys, are interlinked in a cycle such that the first thread forces > them in order xs, ys while the second thread concurrently forces them > in order ys, xs. This

Re: Laziness and deadlocks

2010-04-26 Thread Per Vognsen
On Mon, Apr 26, 2010 at 5:55 PM, Meikel Brandmeyer wrote: > Hi, > > On 26 Apr., 11:22, Per Vognsen wrote: > >> Consider: >> >> (def as (lazy-seq (cons 1 bs))) >> (def bs (lazy-seq (cons 2 cs))) >> ;; ... >> (def zs (lazy-seq (cons 26 as))) >> >> Suppose you start two threads concurrently. The fir

Re: Laziness and deadlocks

2010-04-26 Thread Meikel Brandmeyer
Hi, On 26 Apr., 11:22, Per Vognsen wrote: > Consider: > > (def as (lazy-seq (cons 1 bs))) > (def bs (lazy-seq (cons 2 cs))) > ;; ... > (def zs (lazy-seq (cons 26 as))) > > Suppose you start two threads concurrently. The first forces 'as' and > the second forces 'zs'. If the timing is just right,

Laziness and deadlocks

2010-04-26 Thread Per Vognsen
Consider: (def as (lazy-seq (cons 1 bs))) (def bs (lazy-seq (cons 2 cs))) ;; ... (def zs (lazy-seq (cons 26 as))) Suppose you start two threads concurrently. The first forces 'as' and the second forces 'zs'. If the timing is just right, this can result in a deadlock: // LazySeq.java final synch