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

Unified Diff: src/messages.js

Issue 1302533002: Native context: debug.js does not load from js builtins object anymore. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: make importing requirement more explicit Created 5 years, 4 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/macros.py ('k') | src/prologue.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/messages.js
diff --git a/src/messages.js b/src/messages.js
index a111660bc44804d28d9700088fc45dd963396bc0..32766a89fe4cfa0a48b998145b3dd00efd8d1634 100644
--- a/src/messages.js
+++ b/src/messages.js
@@ -22,38 +22,43 @@ var MakeURIError;
// -------------------------------------------------------------------
// Imports
+var ArrayJoin;
+var Bool16x8ToString;
+var Bool32x4ToString;
+var Bool8x16ToString;
+var Float32x4ToString;
+var FunctionSourceString
var GlobalObject = global.Object;
+var Int16x8ToString;
+var Int32x4ToString;
+var Int8x16ToString;
var InternalArray = utils.InternalArray;
-var ObjectDefineProperty = utils.ObjectDefineProperty;
-
-var ArrayJoin;
+var ObjectDefineProperty;
var ObjectToString;
var StringCharAt;
var StringIndexOf;
var StringSubstring;
-
-var Float32x4ToString;
-var Int32x4ToString;
-var Bool32x4ToString;
-var Int16x8ToString;
-var Bool16x8ToString;
-var Int8x16ToString;
-var Bool8x16ToString;
-
+var ToString;
utils.Import(function(from) {
ArrayJoin = from.ArrayJoin;
+ Bool16x8ToString = from.Bool16x8ToString;
+ Bool32x4ToString = from.Bool32x4ToString;
+ Bool8x16ToString = from.Bool8x16ToString;
+ Float32x4ToString = from.Float32x4ToString;
+ FunctionSourceString = from.FunctionSourceString;
+ Int16x8ToString = from.Int16x8ToString;
+ Int32x4ToString = from.Int32x4ToString;
+ Int8x16ToString = from.Int8x16ToString;
+ ObjectDefineProperty = from.ObjectDefineProperty;
ObjectToString = from.ObjectToString;
StringCharAt = from.StringCharAt;
StringIndexOf = from.StringIndexOf;
StringSubstring = from.StringSubstring;
- Float32x4ToString = from.Float32x4ToString;
- Int32x4ToString = from.Int32x4ToString;
- Bool32x4ToString = from.Bool32x4ToString;
- Int16x8ToString = from.Int16x8ToString;
- Bool16x8ToString = from.Bool16x8ToString;
- Int8x16ToString = from.Int8x16ToString;
- Bool8x16ToString = from.Bool8x16ToString;
+});
+
+utils.ImportNow(function(from) {
+ ToString = from.ToString;
});
// -------------------------------------------------------------------
@@ -81,7 +86,7 @@ function NoSideEffectToString(obj) {
if (IS_UNDEFINED(obj)) return 'undefined';
if (IS_NULL(obj)) return 'null';
if (IS_FUNCTION(obj)) {
- var str = %_CallFunction(obj, obj, $functionSourceString);
+ var str = %_CallFunction(obj, obj, FunctionSourceString);
if (str.length > 128) {
str = %_SubString(str, 0, 111) + "...<omitted>..." +
%_SubString(str, str.length - 2, str.length);
@@ -147,7 +152,7 @@ function ToStringCheckErrorObject(obj) {
if (CanBeSafelyTreatedAsAnErrorObject(obj)) {
return %_CallFunction(obj, ErrorToString);
} else {
- return $toString(obj);
+ return ToString(obj);
}
}
@@ -968,7 +973,7 @@ function DefineError(global, f) {
// object. This avoids going through getters and setters defined
// on prototype objects.
if (!IS_UNDEFINED(m)) {
- %AddNamedProperty(this, 'message', $toString(m), DONT_ENUM);
+ %AddNamedProperty(this, 'message', ToString(m), DONT_ENUM);
}
} else {
return new f(m);
« no previous file with comments | « src/macros.py ('k') | src/prologue.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698