]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/typeof/test/function_ptr_from_tpl.cpp
add subtree-ish sources for 12.0.3
[ceph.git] / ceph / src / boost / libs / typeof / test / function_ptr_from_tpl.cpp
1 // Copyright (C) 2006 Arkadiy Vertleyb
2 // Use, modification and distribution is subject to the Boost Software
3 // License, Version 1.0. (http://www.boost.org/LICENSE_1_0.txt)
4
5 #include <boost/typeof/typeof.hpp>
6 #include <boost/type_traits/is_same.hpp>
7 #include <boost/static_assert.hpp>
8
9 void f()
10 {}
11
12 template<class T>
13 struct tpl
14 {
15 typedef BOOST_TYPEOF_TPL(&f) type;
16 };
17
18 typedef void(*fun_type)();
19
20 BOOST_STATIC_ASSERT((boost::is_same<tpl<void>::type, fun_type>::value));