72 # define DIRSLASH_CHAR '\\' |
71 # define DIRSLASH_CHAR '\\' |
73 #else // WIN32 |
72 #else // WIN32 |
74 # define DIRSLASH "/" |
73 # define DIRSLASH "/" |
75 # define DIRSLASH_CHAR '/' |
74 # define DIRSLASH_CHAR '/' |
76 #endif // WIN32 |
75 #endif // WIN32 |
77 |
|
78 #ifdef RELEASE |
|
79 # define NDEBUG // remove asserts |
|
80 #endif // RELEASE |
|
81 |
76 |
82 #define PROP_NAME(GET) m_##GET |
77 #define PROP_NAME(GET) m_##GET |
83 |
78 |
84 #define READ_ACCESSOR(T, GET) \ |
79 #define READ_ACCESSOR(T, GET) \ |
85 T const& GET() const |
80 T const& GET() const |
142 #define FUNCNAME __func__ |
137 #define FUNCNAME __func__ |
143 #endif // __GNUC__ |
138 #endif // __GNUC__ |
144 |
139 |
145 // Replace assert with a version that shows a GUI dialog if possible. |
140 // Replace assert with a version that shows a GUI dialog if possible. |
146 // On Windows I just can't get the actual error messages otherwise. |
141 // On Windows I just can't get the actual error messages otherwise. |
|
142 void assertionFailure (const char* file, int line, const char* funcname, const char* expr); |
|
143 |
147 #ifdef assert |
144 #ifdef assert |
148 #undef assert |
145 # undef assert |
149 #endif // assert |
146 #endif // assert |
150 |
147 |
151 void assertionFailure (const char* file, int line, const char* funcname, const char* expr); |
148 #ifdef DEBUG |
152 #define assert(N) ((N) ? (void) 0 : assertionFailure (__FILE__, __LINE__, FUNCNAME, #N)) |
149 # define assert(N) ((N) ? (void) 0 : assertionFailure (__FILE__, __LINE__, FUNCNAME, #N)) |
|
150 #else |
|
151 # define assert(N) |
|
152 #endif // DEBUG |
153 |
153 |
154 // Version string identifier |
154 // Version string identifier |
155 QString versionString(); |
155 QString versionString(); |
156 QString versionMoniker(); |
156 QString versionMoniker(); |
157 QString fullVersionString(); |
157 QString fullVersionString(); |