X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fpcl%2Flow.lisp;h=d7ee7a974a6ab203ceb61f9004af8b9ecc4acd99;hb=3fe0010d2777b41e01ea9b4a0f894cfa40f7df1b;hp=deda8ec2039d5ad7392914e74e4b391eaac024e1;hpb=cce46771e6d734c275f3e2d5620004da3b5d09ee;p=sbcl.git diff --git a/src/pcl/low.lisp b/src/pcl/low.lisp index deda8ec..d7ee7a9 100644 --- a/src/pcl/low.lisp +++ b/src/pcl/low.lisp @@ -189,7 +189,7 @@ ;; hasn't been defined by DEFUN. (FIXME: is this right? This logic ;; comes from CMUCL). -- CSR, 2004-12-31 (when (and (consp new-name) - (member (car new-name) '(method fast-method slot-accessor))) + (member (car new-name) '(slow-method fast-method slot-accessor))) (setf (fdefinition new-name) fun)) fun) @@ -352,16 +352,11 @@ #+sb-thread (progn -(defstruct spinlock (value 0)) -(defvar *pcl-lock* (make-spinlock)) + (defvar *pcl-lock* (sb-thread:make-waitqueue)) -(defmacro with-pcl-lock (&body body) - `(progn - (sb-thread::get-spinlock *pcl-lock* 1 (sb-thread::current-thread-id)) - (unwind-protect - (progn ,@body) - (setf (spinlock-value *pcl-lock*) 0)))) -);progn + (defmacro with-pcl-lock (&body body) + `(sb-thread::with-spinlock (*pcl-lock*) + ,@body))) #-sb-thread (defmacro with-pcl-lock (&body body)