summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Benkard <code@mail.matthias.benkard.de>2007-08-03 21:32:22 +0200
committerMatthias Benkard <code@mail.matthias.benkard.de>2007-08-03 21:32:22 +0200
commitf92eae85ac10961c5c605593767689fa9a77efcd (patch)
tree7bdbf5d73c1f6f6424819a94389365ced3bc8441
parentb0a5bbccb99f099046dc15c32939dc0d0c735e02 (diff)
Add generic function OBJCL-EQL.
darcs-hash:278d6402c005d66a4a9fa0951f0a9b34f655d060
-rw-r--r--objcl.lisp7
1 files changed, 7 insertions, 0 deletions
diff --git a/objcl.lisp b/objcl.lisp
index 49085f8..5fcafd4 100644
--- a/objcl.lisp
+++ b/objcl.lisp
@@ -48,6 +48,13 @@
(objcl-invoke-class-method condition "name")))))
+(defgeneric objcl-eql (obj1 obj2))
+(defmethod objcl-eql ((obj1 c-pointer-wrapper) (obj2 c-pointer-wrapper))
+ (pointer-eq (pointer-to obj1) (pointer-to obj2)))
+(defmethod objcl-eql (obj1 obj2)
+ (eql obj1 obj2))
+
+
(defcunion obj-data-union
(id-val :pointer)
(class-val :pointer)