summaryrefslogtreecommitdiff
path: root/libobjcl.h
diff options
context:
space:
mode:
authorMatthias Benkard <code@mail.matthias.benkard.de>2007-08-03 15:03:08 +0200
committerMatthias Benkard <code@mail.matthias.benkard.de>2007-08-03 15:03:08 +0200
commit4b6286e29cf106584566c6d77009f3a4b3e3ed39 (patch)
tree68dc74ec1a9f5485eed4163be8a8658e98251a51 /libobjcl.h
parent714a595eb34406d75ce250477e7042c85c3ad95e (diff)
Use tagged data on both the Lisp and C sides.
darcs-hash:d32babb07560cbb4f8db5467b31a7e92534eeb0d
Diffstat (limited to 'libobjcl.h')
-rw-r--r--libobjcl.h45
1 files changed, 38 insertions, 7 deletions
diff --git a/libobjcl.h b/libobjcl.h
index 0d2f055..65270ed 100644
--- a/libobjcl.h
+++ b/libobjcl.h
@@ -1,22 +1,53 @@
/* -*- mode: objc; coding: utf-8 -*- */
+#import "Foundation/Foundation.h"
+#include <objc/objc-api.h>
+
+typedef struct objcl_object
+{
+ char* type;
+
+ union
+ {
+ id id_val;
+ SEL sel_val;
+ char char_val;
+ short short_val;
+ int int_val;
+ long long_val;
+ long long long_long_val;
+ float float_val;
+ double double_val;
+ BOOL bool_val;
+ char *charptr_val;
+ void *ptr_val;
+ } data;
+} *OBJCL_OBJ_DATA;
+
+
void
-objcl_initialise_runtime ();
+objcl_initialise_runtime (void);
void
-objcl_shutdown_runtime ();
+objcl_shutdown_runtime (void);
void *
-objcl_invoke_instance_method (void *receiver,
- char *const method_name,
+objcl_invoke_instance_method (OBJCL_OBJ_DATA receiver,
+ const char *method_name,
int argc,
...);
void *
-objcl_invoke_class_method (void *class,
- char *const method_name,
+objcl_invoke_class_method (OBJCL_OBJ_DATA class,
+ const char *method_name,
int argc,
...);
void *
-objcl_find_class (char *const class_name);
+objcl_find_class (const char *class_name);
+
+/* Return a null-terminated list of type information strings.
+ The first entry describes the type of the method's return value. */
+char **
+objcl_query_arglist_info (void *receiver,
+ const char *method_name);