Changeset 13228 for trunk/abcl/src/org


Ignore:
Timestamp:
02/25/11 22:43:08 (10 years ago)
Author:
astalla
Message:

Fix incorrect elimination of named local functions declared inline when they're actually reified in the flet/labels body.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/abcl/src/org/armedbear/lisp/compiler-pass1.lisp

    r13222 r13228  
    933933     (dolist (special (flet-free-specials block))
    934934       (push special *visible-variables*))
    935      (setf (flet-form block)
    936      (list* (car form)
    937       (remove-if (lambda (fn)
    938              (and (inline-p (local-function-name fn))
    939             (not (local-function-references-needed-p fn))))
    940            local-functions)
    941       (p1-body (cddr form))))
    942      block)))))
     935           (let ((body (p1-body (cddr form))))
     936             (setf (flet-form block)
     937                   (list* (car form)
     938                          (remove-if (lambda (fn)
     939                                       (and (inline-p (local-function-name fn))
     940                                            (not (local-function-references-needed-p fn))))
     941                                     local-functions)
     942                          body)))
     943           block)))))
    943944
    944945
     
    10341035             (list 'FUNCTION compiland)))
    10351036          ((setf local-function (find-local-function (cadr form)))
    1036            (dformat t "p1-function local function ~S~%" (cadr form))
    1037      ;;we found out that the function needs a reference
    1038      (setf (local-function-references-needed-p local-function) t)
     1037           (dformat "p1-function local function ~S~%" (cadr form))
     1038           ;;we found out that the function needs a reference
     1039           (setf (local-function-references-needed-p local-function) t)
    10391040           (let ((variable (local-function-variable local-function)))
    10401041             (when variable
Note: See TracChangeset for help on using the changeset viewer.