Compiler attempts to take value of special variable when it is unbound

Bug #1738827 reported by Paul F. Dietz on 2017-12-18
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Undecided
Unassigned

Bug Description

(defun f51 ()
  (declare (special *s*))
  (lcm (progv '(*s*) nil *s*)))

==>

The variable *S* is unbound.
   [Condition of type UNBOUND-VARIABLE]
[...]
  0: (SB-C::%CONSTANT-FORM-VALUE *S* NIL NIL)
  1: ((FLET SB-C::CONSTANT-FORM-VALUE* :IN SB-C::CONSTANT-SPECIAL-FORM-VALUE) *S*)
  2: (SB-C::CONSTANT-SPECIAL-FORM-VALUE (PROGV (QUOTE (*S*)) NIL *S*) NIL NIL)
  3: (SB-C::%CONSTANT-FORM-VALUE (PROGV (QUOTE (*S*)) NIL *S*) NIL NIL)
  4: (SB-C::THE-IN-POLICY INTEGER (PROGV (QUOTE (*S*)) NIL *S*) #<SB-C:POLICY ((SB-EXT:INHIBIT-WARNINGS 1) (SPEED 1) (SPACE 1) (SAFETY 1) (DEBUG 1) (COMPILATION-SPEED 1))> #<SB-C::CTRAN 1 {1003FC5CE3}> #<S..
  5: (SB-C::IR1-CONVERT-THE #<SB-C::CTRAN 1 {1003FC5CE3}> #<SB-C::CTRAN 2 {1003FC5F03}>
[...]

summary: - Compiler attempts to take value of special variable at compile time when
- it is unbound
+ Compiler attempts to take value of special variable when it is unbound
Stas Boukarev (stassats) wrote :

In 6ed9af93b00b708b07e68161376a8746ecab7704.

Changed in sbcl:
status: New → Fix Committed
Stas Boukarev (stassats) on 2017-12-29
Changed in sbcl:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers