22 #ifndef Rcpp__sugar__not_h
23 #define Rcpp__sugar__not_h
28 template <
int RTYPE,
bool NA>
33 return Rcpp::traits::is_na<RTYPE>(
x) ? NA_LOGICAL : (x ? FALSE : TRUE) ;
41 return x ? FALSE : TRUE ;
55 return ( x == 0.0 ? FALSE : TRUE ) ;
61 inline int apply( Rcomplex
x )
const {
68 inline int apply( Rcomplex
x )
const {
69 return ((x.r == 0.0) & (x.i == 0.0) ) ? FALSE : TRUE ;
75 template <
int RTYPE,
bool NA,
typename T>
99 template <
int RTYPE,
bool NA,
typename T>