bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#20123: 24.4.91; Unwarranted "Unused lexical argument" for condition-


From: Stefan Monnier
Subject: bug#20123: 24.4.91; Unwarranted "Unused lexical argument" for condition-case
Date: Mon, 16 Mar 2015 15:09:13 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> Hello,
> Here's an example code:

>     (define-error 'unsupported-mode-error "Unsupported mode")
>     (condition-case e
>         (if (eq 'a 'a)
>             (message "test")
>           (signal 'unsupported-mode-error major-mode))
>       (unsupported-mode-error
>        (signal (car e) (cdr e)))
>       (error
>        (message "error")))

> As you can see, I'm trying to re-throw some of the errors, so the variable 
> `e' is used
> inside `condition-case'. But I still get an "Unused lexical argument" warning.

Yes, IIRC this bug was introduced in 24.1.  It should be partially fixed
in 24.4 if you set byte-compile--use-old-handlers to nil.  It should be
fixed in 25.1 where this var defaults to nil.

Can you confirm?


        Stefan





reply via email to

[Prev in Thread] Current Thread [Next in Thread]