Added Logo
This commit is contained in:
@@ -20,7 +20,7 @@
|
||||
#ifndef FENNEC_LANG_INTRINSICS_H
|
||||
#define FENNEC_LANG_INTRINSICS_H
|
||||
|
||||
// Most major compilers support __has_builtin
|
||||
// Most major compilers support __has_builtin, notably GCC, MINGW, CLANG, and MSVC
|
||||
#if defined(__has_builtin)
|
||||
|
||||
|
||||
@@ -91,6 +91,14 @@
|
||||
# define FENNEC_HAS_BUILTIN_IS_STANDARD_LAYOUT 0
|
||||
#endif
|
||||
|
||||
// Difficult and Inconsistent without intrinsics
|
||||
#if __has_builtin(__is_constructible)
|
||||
# define FENNEC_BUILTIN_CAN_CONSTRUCT 1
|
||||
# define FENNEC_BUILTIN_CAN_CONSTRUCT(type, args...) __is_constructible(type, args)
|
||||
#else
|
||||
# define FENNEC_HAS_BUILTIN_CAN_CONSTRUCT 0
|
||||
#endif
|
||||
|
||||
|
||||
// For compilers without or differently named builtins
|
||||
#else
|
||||
|
||||
@@ -204,8 +204,18 @@ template<typename T0, typename T1> struct can_convert
|
||||
/// \brief shorthand
|
||||
/// \param T0 First type
|
||||
/// \param T1 Second type
|
||||
template<typename T0, typename T1> using can_convert_v = typename can_convert<T0, T1>::type;
|
||||
template<typename T0, typename T1> using can_convert_v
|
||||
= typename can_convert<T0, T1>::type;
|
||||
|
||||
|
||||
// fennec::is_constructible ============================================================================================
|
||||
|
||||
|
||||
template<typename ClassT, typename...ArgsT> struct can_construct
|
||||
: bool_constant<FENNEC_BUILTIN_CAN_CONSTRUCT(ClassT, ArgsT...)> {};
|
||||
|
||||
template<typename ClassT, typename...ArgsT> constexpr bool_t can_construct_v
|
||||
= can_construct<ClassT, ArgsT...>{};
|
||||
|
||||
//
|
||||
|
||||
|
||||
Reference in New Issue
Block a user