-
- // Convenience extension access when the type has a associated EXTENSION ID:
- template<class U> U* extension() { return extension<U>(U::EXTENSION_ID); }
+ // void* version, for C users and nostalgics
+ void set_data(void* data){
+ extensions_[0]=data;
+ }
+ template <typename D> D* get_data() const { return static_cast<D*>(extensions_[0]); }
+ XBT_ATTRIB_DEPRECATED_v334("Please use typed template Extendable::get_data<>()") void* get_data() const
+ {
+ return get_data<void>();
+ }
+ // Convenience extension access when the type has an associated EXTENSION ID:
+ template <class U> U* extension() const { return extension<U>(U::EXTENSION_ID); }