GNU bug report logs - #12367
24.2.50; cl-defun: unused key args are picked up as unused variables

Previous Next

Package: emacs;

Reported by: Christopher Schmidt <christopher <at> ch.ristopher.com>

Date: Thu, 6 Sep 2012 12:20:02 UTC

Severity: minor

Found in version 24.2.50

Done: Christopher Schmidt <christopher <at> ch.ristopher.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: 12367 <at> debbugs.gnu.org
Subject: bug#12367: 24.2.50; cl-defun: unused key args are picked up as unused variables
Date: Thu, 06 Sep 2012 10:18:14 -0400
>     ;; -*- lexical-binding: t -*-
>     (require 'cl-lib)
>     (cl-defun rms (&key foo))
> Byte compile this piece of code.
>     Warning: Unused lexical variable `foo'

The warning is fine.  But I guess the problem is that the normal fix
(which is to rename `foo' to `_foo') won't work because it forces
callers to use :_foo which is wrong.


        Stefan




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

Previous Next


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