KDECore
Go to the documentation of this file.
28 #ifndef _KDE_MACROS_H_
29 #define _KDE_MACROS_H_
31 #cmakedefine __KDE_HAVE_GCC_VISIBILITY
72 #ifdef __KDE_HAVE_GCC_VISIBILITY
73 #define KDE_NO_EXPORT __attribute__ ((visibility("hidden")))
74 #define KDE_EXPORT __attribute__ ((visibility("default")))
75 #define KDE_IMPORT __attribute__ ((visibility("default")))
76 #elif defined(_WIN32) || defined(_WIN64)
78 #define KDE_EXPORT __declspec(dllexport)
79 #define KDE_IMPORT __declspec(dllimport)
95 #define KDE_PACKED __attribute__((__packed__))
162 # include <QtCore/qglobal.h>
163 # ifndef KDE_DEPRECATED
164 # ifdef KDE_DEPRECATED_WARNINGS
165 # define KDE_DEPRECATED Q_DECL_DEPRECATED
167 # define KDE_DEPRECATED
198 #ifndef KDE_CONSTRUCTOR_DEPRECATED
200 # if __GNUC__ == 3 && __GNUC_MINOR__ <= 3
202 # define KDE_CONSTRUCTOR_DEPRECATED
204 # define KDE_CONSTRUCTOR_DEPRECATED Q_DECL_CONSTRUCTOR_DEPRECATED
207 # define KDE_CONSTRUCTOR_DEPRECATED Q_DECL_CONSTRUCTOR_DEPRECATED
218 #cmakedefine KDE_NO_DEPRECATED
280 #if defined(__GNUC__) && __GNUC__ - 0 >= 3
281 # define KDE_ISLIKELY( x ) __builtin_expect(!!(x),1)
282 # define KDE_ISUNLIKELY( x ) __builtin_expect(!!(x),0)
284 # define KDE_ISLIKELY( x ) ( x )
285 # define KDE_ISUNLIKELY( x ) ( x )
301 #define RESERVE_VIRTUAL_1 \
302 virtual void reservedVirtual1() {}
306 #define RESERVE_VIRTUAL_2 \
307 virtual void reservedVirtual2() {} \
312 #define RESERVE_VIRTUAL_3 \
313 virtual void reservedVirtual3() {} \
318 #define RESERVE_VIRTUAL_4 \
319 virtual void reservedVirtual4() {} \
324 #define RESERVE_VIRTUAL_5 \
325 virtual void reservedVirtual5() {} \
330 #define RESERVE_VIRTUAL_6 \
331 virtual void reservedVirtual6() {} \
336 #define RESERVE_VIRTUAL_7 \
337 virtual void reservedVirtual7() {} \
342 #define RESERVE_VIRTUAL_8 \
343 virtual void reservedVirtual8() {} \
348 #define RESERVE_VIRTUAL_9 \
349 virtual void reservedVirtual9() {} \
351 #define RESERVE_VIRTUAL_10 \
352 virtual void reservedVirtual10() {} \
396 #ifdef KDE_FULL_TEMPLATE_EXPORT_INSTANTIATION
397 # define KDE_DUMMY_COMPARISON_OPERATOR(C) \
398 bool operator==(const C&) const { \
399 qWarning(#C"::operator==(const "#C"&) was called"); \
402 # define KDE_DUMMY_QHASH_FUNCTION(C) \
403 inline uint qHash(const C) { \
404 qWarning("inline uint qHash(const "#C") was called"); \
408 # define KDE_DUMMY_COMPARISON_OPERATOR(C)
409 # define KDE_DUMMY_QHASH_FUNCTION(C)
435 # define KDE_BF_ENUM(a) unsigned int
436 # define KDE_CAST_BF_ENUM(a,b) static_cast<a>(b)
438 # define KDE_BF_ENUM(a) a
439 # define KDE_CAST_BF_ENUM(a,b) b
452 #define KDE_WEAK_SYMBOL __attribute__((__weak__))
454 #define KDE_WEAK_SYMBOL
467 #define KDE_MUST_USE_RESULT __attribute__((__warn_unused_result__))
469 #define KDE_MUST_USE_RESULT
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:47:08 by
doxygen 1.8.7 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.