GNU bug report logs - #16238
24.3.50; pcase docs (and possibly pcase) wrong

Previous Next

Package: emacs;

Reported by: Tassilo Horn <tsdh <at> gnu.org>

Date: Tue, 24 Dec 2013 09:15:02 UTC

Severity: minor

Found in version 24.3.50

Done: Tassilo Horn <tsdh <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Tassilo Horn <tsdh <at> gnu.org>
To: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
Cc: Michael Heerdegen <michael_heerdegen <at> web.de>, 16238 <at> debbugs.gnu.org
Subject: bug#16238: 24.3.50; pcase docs (and possibly pcase) wrong
Date: Tue, 24 Dec 2013 16:34:31 +0100
Stefan Monnier <monnier <at> IRO.UMontreal.CA> writes:

>> (defun evaluate (exp env)
>>   (pcase exp
>>     (`(add ,x ,y)         (+ (evaluate x env) (evaluate y env)))
>>     (`(call ,fun ,arg)    (funcall (evaluate fun) (evaluate arg env)))
>>                                                 `--- HERE!
>
> Indeed, feel free to fix it.

Done.

>> But shouldn't `arg' be substituted with 'x and `body' with '(add 1
>> x)?
>
> No, the code is meant for lexical-binding.

Ok, I see.  I've also mentioned that in the docs, though I guess you can
refine that comment to be more specific.

Bye,
Tassilo




This bug report was last modified 11 years and 155 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.