Use iterate in place of non-ansi-conforming usage of loop
authorDmitry Kalyanov <Kalyanov.Dmitry@gmail.com>
Sat, 2 Apr 2011 18:43:16 +0000 (22:43 +0400)
committerDmitry Kalyanov <Kalyanov.Dmitry@gmail.com>
Sat, 2 Apr 2011 18:43:16 +0000 (22:43 +0400)
glib/gobject.object.high.lisp

index db156d1..f2b07b2 100644 (file)
   (gethash name *registered-object-types*))
 (defun get-g-object-lisp-type (g-type)
   (setf g-type (gtype g-type))
-  (loop
-     while (not (null g-type))
-     for lisp-type = (gethash (gtype-name g-type) *registered-object-types*)
-     when lisp-type do (return lisp-type)
-     do (setf g-type (g-type-parent g-type))))
+  (iter (while (not (null g-type)))
+        (for lisp-type = (gethash (gtype-name g-type) *registered-object-types*))
+        (when lisp-type
+          (return lisp-type))
+        (setf g-type (g-type-parent g-type))))
 
 (defun make-g-object-from-pointer (pointer)
   (let* ((g-type (g-type-from-instance pointer))