Re: Mysterious errors w/ protocols and types

2009-11-23 Thread samppi
I see; then that of course would be the reason. Thanks for the answer. On Nov 23, 12:24 pm, Rich Hickey wrote: > On Nov 23, 11:36 am, samppi wrote: > > > > > > > Variable-length arguments in protocols seem to be supported, but > > there's just a weird, stateful behavior. Look what happens when y

Re: Mysterious errors w/ protocols and types

2009-11-23 Thread Rich Hickey
On Nov 23, 11:36 am, samppi wrote: > Variable-length arguments in protocols seem to be supported, but > there's just a weird, stateful behavior. Look what happens when you > call foo first with one argument twice (it fails both times), then two > arguments (it succeeds), then one argument again

Re: Mysterious errors w/ protocols and types

2009-11-23 Thread samppi
Variable-length arguments in protocols seem to be supported, but there's just a weird, stateful behavior. Look what happens when you call foo first with one argument twice (it fails both times), then two arguments (it succeeds), then one argument again (it succeeds now too!). Is this a Clojure bug?

Re: Mysterious errors w/ protocols and types

2009-11-23 Thread Krukow
On Nov 23, 7:36 am, samppi wrote: > The following code contains an error, and I cannot figure out what it > is at all. When I run StateMeta's test once, the statement marked with > a comment above fails. When I run it again, it succeeds. This has been > causing very weird bugs in my code. I've r

Mysterious errors w/ protocols and types

2009-11-22 Thread samppi
The following code contains an error, and I cannot figure out what it is at all. When I run StateMeta's test once, the statement marked with a comment above fails. When I run it again, it succeeds. This has been causing very weird bugs in my code. I've replicated the behavior in both a script and t