diff options
author | Robin Gareus <robin@gareus.org> | 2016-02-21 19:25:42 +0100 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-02-22 22:06:47 +0100 |
commit | 12a58015a3810ed9df4661cee88be2563ea3db4e (patch) | |
tree | 13ff54b946696364f9f7ea9484522f2174908aca /libs/lua/LuaBridge/detail/TypeTraits.h | |
parent | 5b40e073e9c973479c3d286a007c57e1e0fa3d0f (diff) |
customize LuaBridge
* introduce boost::shared_ptr support
* support enum & const
* allow to add non-class member functions
* STL iterators (vector, list, set, bitset & map)
* support reference arguments (framecnt_t&)
* add support for arrays of basic types (e.g. float*, int*)
* fix compiler warnings
Diffstat (limited to 'libs/lua/LuaBridge/detail/TypeTraits.h')
-rw-r--r-- | libs/lua/LuaBridge/detail/TypeTraits.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libs/lua/LuaBridge/detail/TypeTraits.h b/libs/lua/LuaBridge/detail/TypeTraits.h index a6b9323393..ffb437f658 100644 --- a/libs/lua/LuaBridge/detail/TypeTraits.h +++ b/libs/lua/LuaBridge/detail/TypeTraits.h @@ -89,6 +89,16 @@ struct TypeTraits static const bool value = sizeof (test <ContainerTraits <T> >(0)) == sizeof (yes); }; + /** Determine if T is an enum */ + template <typename T> + class isEnum + { + public: + //static const bool value = std::is_enum<T>::value; // C++11 + static const bool value = boost::is_enum<T>::value; + }; + + /** Determine if T is const qualified. */ /** @{ */ |