From: Alexey D. <ade...@co...> - 2003-01-24 06:04:24
|
Hello, Christophe Rhodes <cs...@ca...> writes: > * (defmethod foo ((x integer)) (class-of x)) > ; in: LAMBDA NIL > ; (CLASS-OF X) > ; --> BLOCK SB-KERNEL:LAYOUT-CLASS SB-KERNEL:LAYOUT-OF BLOCK COND IF COND IF > ; --> COND IF PROGN LOCALLY > ; ==> > ; (SB-KERNEL:CLASS-LAYOUT (FIND-CLASS 'NULL)) > ; > ; note: deleting unused function > ; SB-KERNEL:CLASS-LAYOUT > ; compilation unit finished > ; printed 1 note > > This presumably comes from the inlining of SB-KERNEL:LAYOUT-OF [...] > And how can > we shut it up sanely? Inline expanded CLAMBDAs are not marked to be ``used'', and if they are later deleted, a note is emitted. This patch should close it: ------------------------------------------------------------------------------ Index: ir1util.lisp =================================================================== RCS file: /mnt/hd2/lesha/cvsroot/sbcl/src/compiler/ir1util.lisp,v retrieving revision 1.1.1.23 diff -u -F^( -u -r1.1.1.23 ir1util.lisp --- ir1util.lisp 2003/01/20 08:11:33 1.1.1.23 +++ ir1util.lisp 2003/01/24 05:54:29 @@ -1246,6 +1246,7 @@ (defun change-ref-leaf (ref leaf) (push ref (leaf-refs leaf)) (delete-ref ref) (setf (ref-leaf ref) leaf) + (setf (leaf-ever-used leaf) t) (let ((ltype (leaf-type leaf))) (if (fun-type-p ltype) (setf (node-derived-type ref) ltype) ------------------------------------------------------------------------------ -- Regards, Alexey Dejneka |