24 #ifndef RCPP__HASH__SELF_HASH_H
25 #define RCPP__HASH__SELF_HASH_H
41 while(
m < desired ){
m *= 2 ;
k++ ; }
48 int* res = INTEGER(
result) ;
68 if (addr ==
static_cast<unsigned int>(
m)) addr = 0;
79 unsigned int addr =
get_addr(value) ;
81 if (
src[
data[addr] - 1] == value)
84 if (addr ==
static_cast<unsigned int>(
m)) addr = 0;
106 if (val == 0.0) val = 0.0;
107 if (internal::Rcpp_IsNA(val)) val = NA_REAL;
108 else if (internal::Rcpp_IsNaN(val)) val = R_NaN;
110 addr =
RCPP_HASH(val_u.u[0] + val_u.u[1]);
116 intptr_t val = (intptr_t) value;
118 #if (defined _LP64) || (defined __LP64__) || (defined WIN64)
119 addr =
RCPP_HASH((val & 0xffffffff) ^ (val >> 32));
unsigned int get_index(STORAGE value) const
IntegerVector fill_and_self_match()
unsigned int get_addr(STORAGE value) const
std::vector< int > indices
int add_value_get_index(int i)
traits::storage_type< RTYPE >::type STORAGE
no_init_vector no_init(R_xlen_t size)
IntegerVector table(const VectorBase< RTYPE, NA, T > &x)