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

Unified Diff: src/v8natives.js

Issue 1400973002: Throw when calling an undefined function Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 2 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/parser.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/v8natives.js
diff --git a/src/v8natives.js b/src/v8natives.js
index a0c6b5b67d3fca6ab7310f76f2af067030fcff3a..e751ed56244724dba804cc5cfa41d3a93c7c045e 100644
--- a/src/v8natives.js
+++ b/src/v8natives.js
@@ -108,6 +108,11 @@ function GlobalEval(x) {
}
+function GlobalThrowLittleDan() {
+ throw "LittleDan!"
+}
+
+
// ----------------------------------------------------------------------------
// Set up global object.
@@ -128,7 +133,8 @@ utils.InstallFunctions(global, DONT_ENUM, [
"isFinite", GlobalIsFinite,
"parseInt", GlobalParseInt,
"parseFloat", GlobalParseFloat,
- "eval", GlobalEval
+ "eval", GlobalEval,
+ "throwLittleDan", GlobalThrowLittleDan
]);
« no previous file with comments | « src/parser.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698