add another condition on Function in-place optimization

master
Daniel Kolesa 2015-04-23 21:05:09 +01:00
parent e92f5bba4b
commit 89bab3362b
1 changed files with 2 additions and 1 deletions

View File

@ -200,7 +200,8 @@ namespace octa {
template<typename T>
struct FunctorInPlace {
static constexpr bool value = sizeof(T) <= sizeof(FunctorData)
&& (alignof(FunctorData) % alignof(T)) == 0;
&& (alignof(FunctorData) % alignof(T)) == 0
&& octa::IsNothrowMoveConstructible<T>::value;
};
template<typename T, typename E = void>