[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Warning for arity mismatches
From: |
Ludovic Courtès |
Subject: |
Re: Warning for arity mismatches |
Date: |
Sun, 08 Nov 2009 01:19:51 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
Hey,
Andy Wingo <address@hidden> writes:
> On Sat 07 Nov 2009 19:38, address@hidden (Ludovic Courtès) writes:
[...]
>> It currently lacks support for keyword
>> arguments, which is why it’s not ready yet to compile Guile itself (it
>> produces erroneous warnings for procedures with keyword arguments.)
>
> Why doesn't it just not warn in that case?
It now supports keyword arguments for good, so forget about it. :-)
>> I think some of these warnings should really be errors, when there’s
>> undoubtedly a wrong number of arguments, as in:
>>
>> (let ((f (lambda (x) x)))
>> (f 1 2 3))
>>
>> What do you think?
>
> I think there should be a -Werror compilation argument, but that we
> should, by default, compile all expressions. It could very well be that
> the user wanted to cause an exception to be raised.
Right, why not. With backwards compatibility in mind, it seems to me
like a reasonable approach
Thanks,
Ludo’.