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

Unified Diff: runtime/lib/math.cc

Issue 2974233002: VM: Re-format to use at most one newline between functions (Closed)
Patch Set: Rebase and merge Created 3 years, 5 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 | « runtime/lib/linked_hash_map.cc ('k') | runtime/lib/mirrors.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/math.cc
diff --git a/runtime/lib/math.cc b/runtime/lib/math.cc
index d95e32ff8eb578a764f2ee3632d2861341707189..6ca979391b8558df1141d1df6649d6af62ab003c 100644
--- a/runtime/lib/math.cc
+++ b/runtime/lib/math.cc
@@ -74,7 +74,6 @@ DEFINE_NATIVE_ENTRY(Math_doublePow, 2) {
return Double::New(pow(operand, exponent));
}
-
// Returns the typed-data array store in '_Random._state' field.
static RawTypedData* GetRandomStateArray(const Instance& receiver) {
const Class& random_class = Class::Handle(receiver.clazz());
@@ -91,7 +90,6 @@ static RawTypedData* GetRandomStateArray(const Instance& receiver) {
return array.raw();
}
-
// Implements:
// var state =
// ((_A * (_state[_kSTATE_LO])) + _state[_kSTATE_HI]) & (1 << 64) - 1);
@@ -110,7 +108,6 @@ DEFINE_NATIVE_ENTRY(Random_nextState, 1) {
return Object::null();
}
-
RawTypedData* CreateRandomState(Zone* zone, uint64_t seed) {
const TypedData& result =
TypedData::Handle(zone, TypedData::New(kTypedDataUint32ArrayCid, 2));
@@ -120,7 +117,6 @@ RawTypedData* CreateRandomState(Zone* zone, uint64_t seed) {
return result.raw();
}
-
uint64_t mix64(uint64_t n) {
// Thomas Wang 64-bit mix.
// http://www.concentric.net/~Ttwang/tech/inthash.htm
@@ -135,7 +131,6 @@ uint64_t mix64(uint64_t n) {
return n;
}
-
// Implements:
// uint64_t hash = 0;
// do {
@@ -191,7 +186,6 @@ DEFINE_NATIVE_ENTRY(Random_setupSeed, 1) {
return CreateRandomState(zone, seed);
}
-
DEFINE_NATIVE_ENTRY(Random_initialSeed, 0) {
Random* rnd = isolate->random();
uint64_t seed = rnd->NextUInt32();
@@ -199,7 +193,6 @@ DEFINE_NATIVE_ENTRY(Random_initialSeed, 0) {
return CreateRandomState(zone, seed);
}
-
DEFINE_NATIVE_ENTRY(SecureRandom_getBytes, 1) {
GET_NON_NULL_NATIVE_ARGUMENT(Smi, count, arguments->NativeArgAt(0));
const intptr_t n = count.Value();
« no previous file with comments | « runtime/lib/linked_hash_map.cc ('k') | runtime/lib/mirrors.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698