[slime-cvs] CVS slime

nsiivola nsiivola at common-lisp.net
Wed Aug 6 09:17:01 UTC 2008


Update of /project/slime/cvsroot/slime
In directory clnet:/tmp/cvs-serv6601

Modified Files:
	ChangeLog swank-sbcl.lisp 
Log Message:
No SBCL style-warnings for definitions inside EVAL-WHEN :COMPILE-TOPLEVEL

--- /project/slime/cvsroot/slime/ChangeLog	2008/08/05 18:19:33	1.1396
+++ /project/slime/cvsroot/slime/ChangeLog	2008/08/06 09:16:54	1.1397
@@ -1,3 +1,14 @@
+2008-08-06  Nikodemus Siivola <nikodemus at random-state.net>
+
+	* swank-sbcl.lisp (handle-notification-condition): resignal
+	warnings as-is before replacing with COMPILER-CONDITION so that
+	handlers higher up the stack can muffle them should they choose
+	to. This silences redefinition warnings for definitions inside
+	EVAL-WHEN :COMPILE-TOPLEVEL in newish SBCLs when compiling the
+	file for a second time.
+	(call-with-compilation-hooks): STYLE-WARNINGs are WARNINGs, and
+	don't need a separate handler.
+
 2008-08-05  Helmut Eller  <heller at common-lisp.net>
 
 	* slime.el (slime-with-output-to-temp-buffer): Make sure that we
--- /project/slime/cvsroot/slime/swank-sbcl.lisp	2008/08/05 17:38:44	1.205
+++ /project/slime/cvsroot/slime/swank-sbcl.lisp	2008/08/06 09:16:55	1.206
@@ -313,10 +313,13 @@
 C:*COMPILER-NOTIFICATION-FUNCTION*. The advantage is that we get to
 craft our own error messages, which can omit a lot of redundant
 information."
-  (let ((context (sb-c::find-error-context nil)))
-    (unless (eq condition *previous-compiler-condition*)
-      (setq *previous-compiler-condition* condition)
-      (signal-compiler-condition condition context))))
+  (unless (or (eq condition *previous-compiler-condition*))
+    ;; First resignal warnings, so that outer handlers -- which may choose to
+    ;; muffle this -- get a chance to run.
+    (when (typep condition 'warning)
+      (signal condition))
+    (setq *previous-compiler-condition* condition)
+    (signal-compiler-condition condition (sb-c::find-error-context nil))))
 
 (defun signal-compiler-condition (condition context)
   (signal (make-condition
@@ -409,7 +412,6 @@
   (handler-bind ((sb-c:fatal-compiler-error #'handle-file-compiler-termination)
                  (sb-c:compiler-error  #'handle-notification-condition)
                  (sb-ext:compiler-note #'handle-notification-condition)
-                 (style-warning        #'handle-notification-condition)
                  (warning              #'handle-notification-condition))
     (funcall function)))
 




More information about the slime-cvs mailing list