From 11c857700e03ec0b758f729731784d0f46a6d55e Mon Sep 17 00:00:00 2001 From: Matthias Benkard Date: Tue, 4 Mar 2008 12:36:06 +0100 Subject: Use INTERN-LISP-VALUE for argument conversion. darcs-hash:2f57dd53bfa6b2aa44474232042d9578af720c22 --- Lisp/method-invocation.lisp | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) (limited to 'Lisp/method-invocation.lisp') diff --git a/Lisp/method-invocation.lisp b/Lisp/method-invocation.lisp index bbbee68..50c3238 100644 --- a/Lisp/method-invocation.lisp +++ b/Lisp/method-invocation.lisp @@ -492,24 +492,10 @@ easier to use with __apply__. 'id x)) -(defcoercion id ((x string)) - (primitive-invoke (find-objc-class 'ns-string) - "stringWithUTF8String:" - 'id - x)) +(defcoercion id ((x null)) + +nil+) -(defcoercion id ((x list)) - ;; Circular lists may cause this to hang. So may lists that contain - ;; themselves, as well as lists that contain other data structures - ;; that contain themselves or this list, and so on. - (apply #'primitive-invoke - (find-objc-class 'ns-array) - "arrayWithObjects:" - 'id - (append (mapcar #'(lambda (element) - (coerce-object element 'id)) - x) - (list +nil+)))) +;; (defcoercion id ((x {list, string, t})) ...): See lisp-value-wrapping.lisp. (defcoercion class ((x id)) -- cgit v1.2.3