[libdispatch-dev] Solaris portability, dispatch_test.h [PATCH]

Joakim Johansson jocke at tbricks.com
Thu Nov 19 07:56:02 PST 2009


Here is the patch for dispatch_test.h, seems to be no reason for and defines in this singular place really...

Joakim

Index: testing/dispatch_test.h
===================================================================
--- testing/dispatch_test.h	(revision 171)
+++ testing/dispatch_test.h	(working copy)
@@ -1,7 +1,9 @@
 #include <errno.h>
 
-__BEGIN_DECLS
-
+#ifdef __cplusplus
+extern "C" {
+#endif
+	
 void test_start(const char* desc);
 void test_stop(void);
 void test_stop_after_delay(void *delay);
@@ -30,4 +32,6 @@
 void _test_errno(const char* file, long line, const char* desc, long actual, long expected);
 #define test_errno(a,b,c) _test_errno(__FILE__, __LINE__, a, b, c)
 
-__END_DECLS
+#ifdef __cplusplus
+}
+#endif

On 13 nov 2009, at 01.13, Robert Watson wrote:
On Tue, 10 Nov 2009, Joakim Johansson wrote:
> 
>> Ok, patch attached below.
>> 
>> I also removed the include of cdefs.h in dispatch.h, as it no longer seems required.
> 
> Committed as r150, but with minor tweaks so that the definitions exactly match those on Mac OS X.  I notice also that dispatch_test.h isn't updated?
> 
> Robert
> 




More information about the libdispatch-dev mailing list