]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | //---------------------------------------------------------------------------// |
2 | // Copyright (c) 2013-2014 Kyle Lutz <kyle.r.lutz@gmail.com> | |
3 | // | |
4 | // Distributed under the Boost Software License, Version 1.0 | |
5 | // See accompanying file LICENSE_1_0.txt or copy at | |
6 | // http://www.boost.org/LICENSE_1_0.txt | |
7 | // | |
8 | // See http://boostorg.github.com/compute for more information. | |
9 | //---------------------------------------------------------------------------// | |
10 | ||
11 | #ifndef BOOST_COMPUTE_TYPE_TRAITS_TYPE_DEFINITION_HPP | |
12 | #define BOOST_COMPUTE_TYPE_TRAITS_TYPE_DEFINITION_HPP | |
13 | ||
14 | #include <string> | |
15 | ||
16 | namespace boost { | |
17 | namespace compute { | |
18 | namespace detail { | |
19 | ||
20 | template<class T> | |
21 | struct type_definition_trait; | |
22 | ||
23 | } // end detail namespace | |
24 | ||
25 | /// Returns the OpenCL type definition for \c T. | |
26 | /// | |
27 | /// \return a string containing the type definition for \c T | |
28 | /// | |
29 | /// \see type_name<T>() | |
30 | template<class T> | |
31 | inline std::string type_definition() | |
32 | { | |
33 | return detail::type_definition_trait<T>::value(); | |
34 | } | |
35 | ||
36 | } // end compute namespace | |
37 | } // end boost namespace | |
38 | ||
39 | #endif // BOOST_COMPUTE_TYPE_TRAITS_TYPE_DEFINITION_HPP |