muffle style-warnings for INFO :FUNCTION :TYPE
authorNikodemus Siivola <nikodemus@random-state.net>
Fri, 2 Dec 2011 12:20:08 +0000 (14:20 +0200)
committerNikodemus Siivola <nikodemus@random-state.net>
Mon, 5 Dec 2011 10:21:18 +0000 (12:21 +0200)
  Even if the function object's type contains unknown types, this is not the
  right place to complain about them.

  lp#806243

NEWS
src/compiler/globaldb.lisp

diff --git a/NEWS b/NEWS
index 5cea3b8..66949cc 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -34,6 +34,8 @@ changes relative to sbcl-1.0.54:
   * bug fix: *EVALUATOR-MODE* :COMPILE treated (LET () ...) identically
     to (LOCALLY ...) leading to internally inconsistent toplevel-formness.
   * bug fix: non-toplevel DEFSTRUCT signaled a style warning for unknown type.
+  * bug fix: redefining a function whose previous definition contained an
+    unknown type no longer causes a style-warning. (lp#806243)
 
 changes in sbcl-1.0.54 relative to sbcl-1.0.53:
   * minor incompatible changes:
index 69c579c..da77f64 100644 (file)
   :default
   #+sb-xc-host (specifier-type 'function)
   #-sb-xc-host (if (fboundp name)
-                   (specifier-type (sb!impl::%fun-type (fdefinition name)))
+                   (handler-bind ((style-warning #'muffle-warning))
+                     (specifier-type (sb!impl::%fun-type (fdefinition name))))
                    (specifier-type 'function)))
 
 ;;; the ASSUMED-TYPE for this function, if we have to infer the type