Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Unified Diff: test/cctest/test-strings.cc

Issue 23548024: Introduce a RandonNumberGenerator class. Refactor the random/private_random uses in Isolate/Context. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/cctest/test-spaces.cc ('k') | test/cctest/test-strtod.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-strings.cc
diff --git a/test/cctest/test-strings.cc b/test/cctest/test-strings.cc
index 726188d917d231b16c8bf019dcd9d4d9182d65da..9049df1b72b402f9d7a8c56592c37f11b54522ea 100644
--- a/test/cctest/test-strings.cc
+++ b/test/cctest/test-strings.cc
@@ -41,9 +41,9 @@
#include "zone-inl.h"
// Adapted from http://en.wikipedia.org/wiki/Multiply-with-carry
-class RandomNumberGenerator {
+class MyRandomNumberGenerator {
public:
- RandomNumberGenerator() {
+ MyRandomNumberGenerator() {
init();
}
@@ -133,7 +133,7 @@ class AsciiResource: public v8::String::ExternalAsciiStringResource,
static void InitializeBuildingBlocks(Handle<String>* building_blocks,
int bb_length,
bool long_blocks,
- RandomNumberGenerator* rng,
+ MyRandomNumberGenerator* rng,
Zone* zone) {
// A list of pointers that we don't have any interest in cleaning up.
// If they are reachable from a root then leak detection won't complain.
@@ -276,7 +276,7 @@ class ConsStringGenerationData {
// Cached data.
Handle<String> building_blocks_[kNumberOfBuildingBlocks];
String* empty_string_;
- RandomNumberGenerator rng_;
+ MyRandomNumberGenerator rng_;
// Stats.
ConsStringStats stats_;
unsigned early_terminations_;
« no previous file with comments | « test/cctest/test-spaces.cc ('k') | test/cctest/test-strtod.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698