// // Test that a base_from_member can be properly constructed // // Copyright 2014 Agustin Berge // // Distributed under the Boost Software License, Version 1.0. // See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt // #include #include struct foo : boost::base_from_member { explicit foo(int& ref) : boost::base_from_member(ref) { BOOST_TEST(&member == &ref); } }; int main() { int i = 0; foo f(i); return boost::report_errors(); }