diff options
author | Matthias Benkard <code@mail.matthias.benkard.de> | 2007-08-06 17:44:07 +0200 |
---|---|---|
committer | Matthias Benkard <code@mail.matthias.benkard.de> | 2007-08-06 17:44:07 +0200 |
commit | e562ec45a61b6b60fdbacf609ece03d998452b95 (patch) | |
tree | d99d9d1cd257c7d0d46fba9c508741de12cca5c0 /Lisp/libobjcl.lisp | |
parent | c191d8f49e58bbc5b769780a0a17b5cec82174f1 (diff) |
Minor cleanups.
darcs-hash:ee74b33660af9dc6b1e0207285907211dd7e600a
Diffstat (limited to 'Lisp/libobjcl.lisp')
-rw-r--r-- | Lisp/libobjcl.lisp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Lisp/libobjcl.lisp b/Lisp/libobjcl.lisp index fff0963..9591f8f 100644 --- a/Lisp/libobjcl.lisp +++ b/Lisp/libobjcl.lisp @@ -147,26 +147,25 @@ conventional case for namespace identifiers in Objective C." (defun find-objc-class-by-name (class-name) - (let ((obj-data (%objcl-find-class class-name))) + (with-foreign-objects ((obj-data (%objcl-find-class class-name))) (unwind-protect (if (null-pointer-p (foreign-slot-value (foreign-slot-value obj-data 'obj-data 'data) 'obj-data-union 'class-val)) nil - (obj-data->lisp obj-data)) - (dealloc-obj-data obj-data)))) + (obj-data->lisp obj-data))))) (defun objcl-class-name (class) (declare (type (or objc-class id exception) class)) - (with-foreign-objects ((obj-data class)) + (with-foreign-conversion ((obj-data class)) (%objcl-class-name obj-data))) (defun selector-name (selector) (declare (type selector selector)) - (with-foreign-objects ((obj-data selector)) + (with-foreign-conversion ((obj-data selector)) (%objcl-selector-name obj-data))) |