
Hi again, Andrej van der Zee ha escrito:
Hi,
I am trying to set up a multi_index_container-type with a template argument like this:
template <typename event_type> struct mi_container { typedef typename mi::composite_key< event_type, mi::const_mem_fun<fields::field_ts, ts_type, &fields::field_ts::ts>, mi::const_mem_fun<fields::field_addr, addr_type, &fields::field_addr::addr>, mi::const_mem_fun<fields::field_port, port_type, &fields::field_port::port>
self_key_type; [...] };
mi_container<ev_connect>::type connected;
This gives me the following compile-error:
main.cpp: In instantiation of [...] event::fields::field_ts::ts to form a pointer-to-member-function main.cpp:75: note: a qualified-id is required
Probably I doing something silly. Note that if I remove the class template and directly specialize it, there is no problem at all. Can anybody help me out?
Ummm... Can you provide more context? Where and how is fields defined, and what its relationship is wrt to event_type? Thank you, Joaquín M López Muñoz Telefónica, Investigación y Desarrollo