#include #include struct N1 { std::string _id; }; struct N2 : public N1 {}; struct C {}; template struct MyClass { typedef boost::adjacency_list graph_t; void test() { boost::dynamic_properties dp; graph_t g; dp.property("node_id", get(&N::_id, g)); } }; // this main compiles with boost 1.38 and boost 1.40 // int main() // { // MyClass a; // a.test(); // } // this ones compiles with boost 1.38 but not with boost 1.40 int main() { MyClass a; a.test(); }