diff mbox

hash policy patch

Message ID 4E2C7722.3090805@oracle.com
State New
Headers show

Commit Message

Paolo Carlini July 24, 2011, 7:48 p.m. UTC
... Francois, your patch, as applied had nasty typos, which probably 
broke the build (or we lacking tons of testcases ;) I committed the below.

Paolo.

PS: I think the fix could be suited also for the branch, maybe after a 
couple of weeks of testing...

///////////////////
2011-07-24  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/hashtable_policy.h (_Prime_rehash_policy::_M_next_bkt,
	_M_bkt_for_elements, _M_need_rehash): Fix typos in the last commit.
diff mbox

Patch

Index: include/bits/hashtable_policy.h
===================================================================
--- include/bits/hashtable_policy.h	(revision 176717)
+++ include/bits/hashtable_policy.h	(working copy)
@@ -431,7 +431,7 @@ 
 						+ _S_n_primes, __n);
     _M_next_resize =
       static_cast<std::size_t>(__builtin_floor(__p * _M_max_load_factor));
-    return *__p;
+    return __p;
   }
 
   // Return the smallest prime p such that alpha p >= n, where alpha
@@ -445,7 +445,7 @@ 
 						+ _S_n_primes, __min_bkts);
     _M_next_resize =
       static_cast<std::size_t>(__builtin_floor(__p * _M_max_load_factor));
-    return *__p;
+    return __p;
   }
 
   // Finds the smallest prime p such that alpha p > __n_elt + __n_ins.
@@ -474,7 +474,7 @@ 
 				__min_bkts);
 	    _M_next_resize = static_cast<std::size_t>
 	      (__builtin_floor(__p * _M_max_load_factor));
-	    return std::make_pair(true, *__p);
+	    return std::make_pair(true, __p);
 	  }
 	else
 	  {