[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] char=? question
From: |
felix winkelmann |
Subject: |
Re: [Chicken-users] char=? question |
Date: |
Thu, 12 Jun 2008 15:31:24 +0200 |
On Thu, Jun 12, 2008 at 2:58 PM, William Ramsay <address@hidden> wrote:
> A quick question. I may be going going insane.
>
> I have the following code:
>
> (define foo
> (lambda (v)
> (let
> ((wa (vector-ref v W1))
> (wb (vector-ref v W2)))
>
> (if (> wb 0)
> (if (char=? wa #\R)
> (bar1 wa wb)
> (bar2 wa wb))))))
>
Chicken here makes something dirty: it replaces char=? with eq?. I assume
you are actually storing numbers (otherwise ">" should fail)?
That replacement is questionable, of course. But your code seems to
mix up argument types.
cheers,
felix