Christian Henning wrote:
Hi there, next metaprogramming problem. Is it possible to extract a tagged type from a map?
namespace fields { struct _id_; struct _name_; struct _birthday_; struct _address_id_; }
namespace tags { struct _primary_key_; struct _foreign_key_; struct _value_; }
typedef fusion::map< fusion::vector< fields::_id_ , std::string, tags::_primary_key_ > , fusion::vector< fields::_name_ , std::string, tags::_value_ > , fusion::vector< fields::_birthday_ , std::string, tags::_value_ > , fusion::vector< fields::_address_id_, std::string, tags::_foreign_key_ > > table_type;
int main() { /// how to get the primary key type vector }
at_keyfields::_id_(m) ???
I was looking at fusion's filter_view but that is only available for non-metaprogramming.
Not sure what you mean. Regards, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net