Chromium Code Reviews| Index: base/rand_util.h |
| diff --git a/base/rand_util.h b/base/rand_util.h |
| index 4e902da2f356ea666098ca3d34b73518f418833a..23783c951daea0eac3d008b2fbde1219d6fe84c5 100644 |
| --- a/base/rand_util.h |
| +++ b/base/rand_util.h |
| @@ -29,6 +29,10 @@ BASE_API uint64 RandGenerator(uint64 max); |
| // Returns a random double in range [0, 1). Thread-safe. |
| BASE_API double RandDouble(); |
| +// Given input |bits|, convert with maximum precision to a rand-like |
| +// double, i.e. in the range [0, 1). Thread-safe. |
|
wtc
2011/05/04 17:58:05
I didn't understand this description of BitsToOpen
Jói
2011/05/04 20:02:09
You're right, I missed removing the "rand-like" th
|
| +BASE_API double BitsToOpenEndedUnitInterval(uint64 bits); |
| + |
| // Returns a random string of the specified length. |
| BASE_API std::string RandBytesAsString(size_t length); |