Refine QADP::pass_parameter_by_value evaluation
Change-Id: I8327ab3eb2503228448af59098146e062d4b90d3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
7075b6eeae
commit
d2cf18bf03
@ -55,7 +55,10 @@ private:
|
||||
public:
|
||||
typedef typename Data::iterator iterator;
|
||||
typedef typename Data::const_iterator const_iterator;
|
||||
enum { pass_parameter_by_value = std::is_fundamental<T>::value || std::is_pointer<T>::value };
|
||||
enum {
|
||||
pass_parameter_by_value =
|
||||
std::is_arithmetic<T>::value || std::is_pointer<T>::value || std::is_enum<T>::value
|
||||
};
|
||||
|
||||
typedef typename std::conditional<pass_parameter_by_value, T, const T &>::type parameter_type;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user