Nevermind - it was late, and I found the error message cryptic.
Sorry for throwing up a red herring.
On Jan 5, 5:30 am, Alessio Stalla wrote:
> On Wednesday, January 5, 2011 11:06:34 AM UTC+1, David wrote:
> > java.lang.String cannot be cast to clojure.lang.IFn
> > [Thrown class java.lang.Cla
On Wednesday, January 5, 2011 11:06:34 AM UTC+1, David wrote:
>
> Consider the two definitions:
>
> (defn if-let-good [str]
> (if-let [rest (seq (drop-while (partial = \a) str))]
> (first rest)
> "empty"))
>
> (defn if-let-bad [seq]
> (if-let [rest (seq (drop-while (partial = \a)
Hello David,
what's the question ?
2011/1/5 David
> Consider the two definitions:
>
> (defn if-let-good [str]
> (if-let [rest (seq (drop-while (partial = \a) str))]
>(first rest)
>"empty"))
>
> (defn if-let-bad [seq]
> (if-let [rest (seq (drop-while (partial = \a) seq))]
>(first r
Consider the two definitions:
(defn if-let-good [str]
(if-let [rest (seq (drop-while (partial = \a) str))]
(first rest)
"empty"))
(defn if-let-bad [seq]
(if-let [rest (seq (drop-while (partial = \a) seq))]
(first rest)
"empty"))
The only difference between them is the name of