aboutsummaryrefslogtreecommitdiff
path: root/libobjc/objc/sarray.h
diff options
context:
space:
mode:
authorAndrew Pinski <apinski@apple.com>2004-06-25 04:31:51 +0000
committerAndrew Pinski <pinskia@gcc.gnu.org>2004-06-24 21:31:51 -0700
commit6f0aa5e195d89a7e494e0362596df853762b4dac (patch)
tree7cd8603cd5e075e1eb7ba55ac5dd364fac92a309 /libobjc/objc/sarray.h
parentfff34d356a721134207d6545fc134a412af8f885 (diff)
downloadgcc-6f0aa5e195d89a7e494e0362596df853762b4dac.zip
gcc-6f0aa5e195d89a7e494e0362596df853762b4dac.tar.gz
gcc-6f0aa5e195d89a7e494e0362596df853762b4dac.tar.bz2
encoding.h: Wrap the functions with extern "C" for C++ mode.
2004-06-24 Andrew Pinski <apinski@apple.com> * objc/encoding.h: Wrap the functions with extern "C" for C++ mode. * objc/hash.h: Likewise. * objc/objc-api.h: Likewise. * objc/objc-list.h: Likewise. * objc/runtime.h: Likewise. * objc/sarray.h: Likewise. * objc/thr.h: Likewise. * objc/typedstream.h: Likewise. From-SVN: r83635
Diffstat (limited to 'libobjc/objc/sarray.h')
-rw-r--r--libobjc/objc/sarray.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/libobjc/objc/sarray.h b/libobjc/objc/sarray.h
index a94a98a..5956a43 100644
--- a/libobjc/objc/sarray.h
+++ b/libobjc/objc/sarray.h
@@ -43,11 +43,20 @@ extern const char* __objc_sparse3_id;
#include "objc/thr.h"
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
+
extern int nbuckets; /* for stats */
extern int nindices;
extern int narrays;
extern int idxsize;
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+
#include <assert.h>
/* An unsigned integer of same size as a pointer */
@@ -142,6 +151,10 @@ struct sarray {
size_t capacity;
};
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
+
struct sarray* sarray_new(int, void* default_element);
void sarray_free(struct sarray*);
struct sarray* sarray_lazy_copy(struct sarray*);
@@ -234,4 +247,9 @@ static inline void* sarray_get_safe(struct sarray* array, sidx indx)
return (array->empty_bucket->elems[0]);
}
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+
#endif /* __sarray_INCLUDE_GNU */