;; License along with this library; if not, write to the Free Software
;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-;; $Id: ffi.lisp,v 1.10 2004/12/26 11:40:14 espen Exp $
+;; $Id: ffi.lisp,v 1.12 2005/01/03 16:35:05 espen Exp $
(in-package "GLIB")
(not supplied-lambda-list)
(namep expr) (member style '(:in :in-out :return)))
(push expr lambda-list))
- (push
- (list (if (namep expr)
- (make-symbol (string expr))
- (gensym))
- expr (mklist type) style) args)))))
+ (push (list (cond
+ ((and (namep expr) (eq style :out)) expr)
+ ((namep expr) (make-symbol (string expr)))
+ ((gensym)))
+ expr (mklist type) style) args)))))
(%defbinding
c-name lisp-name (or supplied-lambda-list (nreverse lambda-list))
(defmethod alien-type ((type (eql 'unsigned-byte)) &rest args)
(destructuring-bind (&optional (size '*)) args
(ecase size
- (#.+bits-of-byte+ '(unsigned-byte 8))
+ (#.+bits-of-byte+ '(unsigned #|-byte|# 8))
(#.+bits-of-short+ 'c-call:unsigned-short)
((* #.+bits-of-int+) 'c-call:unsigned-int)
(#.+bits-of-long+ 'c-call:unsigned-long))))