Commit 37305e91 authored by Mostyn Bramley-Moore's avatar Mostyn Bramley-Moore Committed by Commit Bot

[jumbo] arm64 cctest fixes

Remove more "using" statements.

Bug: chromium:746958
Change-Id: I2f9c45b1ff1d51fc58b7a702fee046ba3c6a7c17
Reviewed-on: https://chromium-review.googlesource.com/693862Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Mostyn Bramley-Moore <mostynb@vewd.com>
Cr-Commit-Position: refs/heads/master@{#48248}
parent a953c6f1
......@@ -44,17 +44,9 @@
#include "include/libplatform/v8-tracing.h"
#include "src/tracing/trace-event.h"
using i::CodeEntry;
using i::CpuProfile;
using i::CpuProfiler;
using i::CpuProfilesCollection;
using i::Heap;
using i::ProfileGenerator;
using i::ProfileNode;
using i::ProfilerEventsProcessor;
using i::ProfilerListener;
using i::ScopedVector;
using i::Vector;
namespace v8 {
namespace internal {
namespace test_cpu_profiler {
// Helper methods
static v8::Local<v8::Function> GetFunction(v8::Local<v8::Context> env,
......@@ -2192,3 +2184,7 @@ TEST(TracingCpuProfiler) {
i::V8::SetPlatformForTesting(old_platform);
}
} // namespace test_cpu_profiler
} // namespace internal
} // namespace v8
......@@ -39,40 +39,23 @@
#include "src/utils.h"
#include "test/cctest/cctest.h"
using ::v8::Context;
using ::v8::Extension;
using ::v8::Function;
using ::v8::FunctionTemplate;
using ::v8::HandleScope;
using ::v8::Local;
using ::v8::Message;
using ::v8::MessageCallback;
using ::v8::Object;
using ::v8::ObjectTemplate;
using ::v8::Persistent;
using ::v8::Script;
using ::v8::StackTrace;
using ::v8::String;
using ::v8::TryCatch;
using ::v8::Undefined;
using ::v8::V8;
using ::v8::Value;
static void ExpectBoolean(Local<Context> context, bool expected,
namespace v8 {
namespace internal {
namespace test_javascript_arm64 {
static void ExpectBoolean(Local<v8::Context> context, bool expected,
Local<Value> result) {
CHECK(result->IsBoolean());
CHECK_EQ(expected, result->BooleanValue(context).FromJust());
}
static void ExpectInt32(Local<Context> context, int32_t expected,
static void ExpectInt32(Local<v8::Context> context, int32_t expected,
Local<Value> result) {
CHECK(result->IsInt32());
CHECK_EQ(expected, result->Int32Value(context).FromJust());
}
static void ExpectNumber(Local<Context> context, double expected,
static void ExpectNumber(Local<v8::Context> context, double expected,
Local<Value> result) {
CHECK(result->IsNumber());
CHECK_EQ(expected, result->NumberValue(context).FromJust());
......@@ -125,7 +108,7 @@ TEST(binary_op) {
ExpectInt32(env.local(), 0x2468, result);
}
static void if_comparison_testcontext_helper(Local<Context> context,
static void if_comparison_testcontext_helper(Local<v8::Context> context,
char const* op, char const* lhs,
char const* rhs, int expect) {
char buffer[256];
......@@ -139,7 +122,7 @@ static void if_comparison_testcontext_helper(Local<Context> context,
ExpectInt32(context, expect, result);
}
static void if_comparison_effectcontext_helper(Local<Context> context,
static void if_comparison_effectcontext_helper(Local<v8::Context> context,
char const* op, char const* lhs,
char const* rhs, int expect) {
char buffer[256];
......@@ -154,7 +137,7 @@ static void if_comparison_effectcontext_helper(Local<Context> context,
ExpectInt32(context, expect, result);
}
static void if_comparison_helper(Local<Context> context, char const* op,
static void if_comparison_helper(Local<v8::Context> context, char const* op,
int expect_when_lt, int expect_when_eq,
int expect_when_gt) {
// TODO(all): Non-SMI tests.
......@@ -259,3 +242,7 @@ TEST(unary_not) {
result = CompileRun("var a = 1; if ( !a ) { 1; } else { 0; }");
ExpectInt32(env.local(), 0, result);
}
} // namespace test_javascript_arm64
} // namespace internal
} // namespace v8
......@@ -41,26 +41,11 @@
#include "src/utils.h"
#include "test/cctest/cctest.h"
using ::v8::Context;
using ::v8::Extension;
using ::v8::Function;
using ::v8::FunctionTemplate;
using ::v8::HandleScope;
using ::v8::Local;
using ::v8::Message;
using ::v8::MessageCallback;
using ::v8::Object;
using ::v8::ObjectTemplate;
using ::v8::Persistent;
using ::v8::Script;
using ::v8::StackTrace;
using ::v8::String;
using ::v8::TryCatch;
using ::v8::Undefined;
using ::v8::V8;
using ::v8::Value;
static void ExpectInt32(Local<Context> context, int32_t expected,
namespace v8 {
namespace internal {
namespace test_js_arm64_variables {
static void ExpectInt32(Local<v8::Context> context, int32_t expected,
Local<Value> result) {
CHECK(result->IsInt32());
CHECK_EQ(expected, result->Int32Value(context).FromJust());
......@@ -140,3 +125,7 @@ TEST(lookup_slots) {
"f5(5);");
ExpectInt32(env.local(), 5, result);
}
} // namespace test_js_arm64_variables
} // namespace internal
} // namespace v8
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment