pip static initializer
This commit is contained in:
@@ -44,10 +44,19 @@
|
||||
# define ADD_NEW_TO_COLLECTION(group, class)
|
||||
|
||||
#else
|
||||
# define ADD_TO_COLLECTION(group, object) static PICollection::CollectionAdder __##group##_##__LINE__##_##adder##__(#group, object, false);
|
||||
# define ADD_TO_COLLECTION_WITH_NAME(group, object, name) static PICollection::CollectionAdder __##group##_##__LINE__##_##adder##__(#group, object, #name, false);
|
||||
# define ADD_NEW_TO_COLLECTION(group, class) static PICollection::CollectionAdder __##group##_##class##_##adder##__(#group, new class(), true);
|
||||
# define ADD_NEW_TO_COLLECTION_WITH_NAME(group, class, name) static PICollection::CollectionAdder __##group##_##class##_##adder##__(#group, new class(), #name, true);
|
||||
|
||||
# define ADD_TO_COLLECTION(group, object) \
|
||||
static PICollection::CollectionAdder _PIP_ADD_COUNTER(_collection_adder_)(#group, object, false);
|
||||
|
||||
# define ADD_TO_COLLECTION_WITH_NAME(group, object, name) \
|
||||
static PICollection::CollectionAdder _PIP_ADD_COUNTER(_collection_adder_)(#group, object, #name, false);
|
||||
|
||||
# define ADD_NEW_TO_COLLECTION(group, class) \
|
||||
static PICollection::CollectionAdder _PIP_ADD_COUNTER(_collection_adder_)(#group, new class(), true);
|
||||
|
||||
# define ADD_NEW_TO_COLLECTION_WITH_NAME(group, class, name) \
|
||||
static PICollection::CollectionAdder _PIP_ADD_COUNTER(_collection_adder_)(#group, new class(), #name, true);
|
||||
|
||||
#endif
|
||||
|
||||
class PIP_EXPORT PICollection
|
||||
|
||||
Reference in New Issue
Block a user