comparison CircularQueue.h @ 71:36644b1b940b

Removed use of dllimport for Windows. Johnson Lin reported that he was getting warnings about it. I think the problem is that I didn't handle the case where you compile the files into your project or statically link. In this case you don't want dllexport or dllimport. From what I read, dllimport is optional (an optimization hint). Since this is becoming a nuisance, I rather just remove it rather than require another build flag.
author Eric Wing <ewing . public |-at-| gmail . com>
date Wed, 20 Jun 2012 10:46:03 -0700
parents 516da6d93534
children 398d1cb12448
comparison
equal deleted inserted replaced
70:7d63f5149d40 71:36644b1b940b
37 37
38 /** Windows needs to know explicitly which functions to export in a DLL. */ 38 /** Windows needs to know explicitly which functions to export in a DLL. */
39 #if defined(_WIN32) 39 #if defined(_WIN32)
40 #if defined(C_CIRCULAR_QUEUE_BUILD_LIBRARY) 40 #if defined(C_CIRCULAR_QUEUE_BUILD_LIBRARY)
41 #define C_CIRCULAR_QUEUE_DECLSPEC __declspec(dllexport) 41 #define C_CIRCULAR_QUEUE_DECLSPEC __declspec(dllexport)
42 #else
43 #define C_CIRCULAR_QUEUE_DECLSPEC __declspec(dllimport)
44 #endif 42 #endif
45 #else 43 #else
46 #if defined(C_CIRCULAR_QUEUE_BUILD_LIBRARY) 44 #if defined(C_CIRCULAR_QUEUE_BUILD_LIBRARY)
47 #if defined (__GNUC__) && __GNUC__ >= 4 45 #if defined (__GNUC__) && __GNUC__ >= 4
48 #define C_CIRCULAR_QUEUE_DECLSPEC __attribute__((visibility("default"))) 46 #define C_CIRCULAR_QUEUE_DECLSPEC __attribute__((visibility("default")))