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

Unified Diff: src/messages.cc

Issue 6685088: Merge isolates to bleeding_edge. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 9 years, 9 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 | « src/mark-compact.cc ('k') | src/messages.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/messages.cc
===================================================================
--- src/messages.cc (revision 7267)
+++ src/messages.cc (working copy)
@@ -32,7 +32,6 @@
#include "execution.h"
#include "messages.h"
#include "spaces-inl.h"
-#include "top.h"
namespace v8 {
namespace internal {
@@ -68,18 +67,18 @@
Vector< Handle<Object> > args,
Handle<String> stack_trace,
Handle<JSArray> stack_frames) {
- Handle<String> type_handle = Factory::LookupAsciiSymbol(type);
+ Handle<String> type_handle = FACTORY->LookupAsciiSymbol(type);
Handle<FixedArray> arguments_elements =
- Factory::NewFixedArray(args.length());
+ FACTORY->NewFixedArray(args.length());
for (int i = 0; i < args.length(); i++) {
arguments_elements->set(i, *args[i]);
}
Handle<JSArray> arguments_handle =
- Factory::NewJSArrayWithElements(arguments_elements);
+ FACTORY->NewJSArrayWithElements(arguments_elements);
int start = 0;
int end = 0;
- Handle<Object> script_handle = Factory::undefined_value();
+ Handle<Object> script_handle = FACTORY->undefined_value();
if (loc) {
start = loc->start_pos();
end = loc->end_pos();
@@ -87,15 +86,15 @@
}
Handle<Object> stack_trace_handle = stack_trace.is_null()
- ? Factory::undefined_value()
+ ? FACTORY->undefined_value()
: Handle<Object>::cast(stack_trace);
Handle<Object> stack_frames_handle = stack_frames.is_null()
- ? Factory::undefined_value()
+ ? FACTORY->undefined_value()
: Handle<Object>::cast(stack_frames);
Handle<JSMessageObject> message =
- Factory::NewJSMessageObject(type_handle,
+ FACTORY->NewJSMessageObject(type_handle,
arguments_handle,
start,
end,
@@ -111,7 +110,7 @@
Handle<Object> message) {
v8::Local<v8::Message> api_message_obj = v8::Utils::MessageToLocal(message);
- v8::NeanderArray global_listeners(Factory::message_listeners());
+ v8::NeanderArray global_listeners(FACTORY->message_listeners());
int global_length = global_listeners.length();
if (global_length == 0) {
DefaultMessageReport(loc, message);
@@ -131,18 +130,21 @@
Handle<String> MessageHandler::GetMessage(Handle<Object> data) {
- Handle<String> fmt_str = Factory::LookupAsciiSymbol("FormatMessage");
+ Handle<String> fmt_str = FACTORY->LookupAsciiSymbol("FormatMessage");
Handle<JSFunction> fun =
- Handle<JSFunction>(JSFunction::cast(
- Top::builtins()->GetPropertyNoExceptionThrown(*fmt_str)));
+ Handle<JSFunction>(
+ JSFunction::cast(
+ Isolate::Current()->js_builtins_object()->
+ GetPropertyNoExceptionThrown(*fmt_str)));
Object** argv[1] = { data.location() };
bool caught_exception;
Handle<Object> result =
- Execution::TryCall(fun, Top::builtins(), 1, argv, &caught_exception);
+ Execution::TryCall(fun,
+ Isolate::Current()->js_builtins_object(), 1, argv, &caught_exception);
if (caught_exception || !result->IsString()) {
- return Factory::LookupAsciiSymbol("<error>");
+ return FACTORY->LookupAsciiSymbol("<error>");
}
Handle<String> result_string = Handle<String>::cast(result);
// A string that has been obtained from JS code in this way is
« no previous file with comments | « src/mark-compact.cc ('k') | src/messages.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698