Ticket #1035 (closed enhancement: fixed)

Opened 23 months ago

Last modified 23 months ago

special variables and declare ignore

Reported by: rme Owned by:
Priority: normal Milestone:
Component: Compiler Version: trunk
Keywords: Cc:

Description

The spec says that a warning should be issued if a variable declared to be ignored is declared SPECIAL, as in:

(defun foo (x y)
 (declare (ignore y))
 ...
 (locally
   (declare (special y))
   ...))

That code doesn't make much sense, but it clearly deservers a warning.

(defparameter y ...)

(defun foo (x y)
 (declare (ignore y))
 ...)

is about the same thing, but the warning in both cases should probably complain that inconsistent declarations applied to Y and not just say that it "wasn't IGNOREd".

Change History

comment:1 Changed 23 months ago by gb

  • Status changed from new to closed
  • Resolution set to fixed

(In [15528]) Try to emit a clearer warning if a SPECIAL variable is declared IGNORE. Fixes ticket:1035 in the trunk.

comment:2 Changed 23 months ago by gb

(In [15530]) Try again; fix ticket:1035 in the trunk (without breaking everything else).

Note: See TracTickets for help on using tickets.