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

Unified Diff: src/messages.js

Issue 1049323003: ES6: Error functions should extend Error (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix and cleanup test Created 5 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 | « no previous file | test/mjsunit/get-prototype-of.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 fe4098fb089871d06f01de5141cf2829937a0f40..c1d38f22c49b8724dadd30bea574fd5d2b623135 100644
--- a/src/messages.js
+++ b/src/messages.js
@@ -1172,10 +1172,11 @@ function SetUpError() {
%FunctionSetPrototype(f, new ErrorPrototype());
} else {
%FunctionSetPrototype(f, new $Error());
+ %InternalSetPrototype(f, $Error);
}
%FunctionSetInstanceClassName(f, 'Error');
%AddNamedProperty(f.prototype, 'constructor', f, DONT_ENUM);
- %AddNamedProperty(f.prototype, "name", name, DONT_ENUM);
+ %AddNamedProperty(f.prototype, 'name', name, DONT_ENUM);
%SetCode(f, function(m) {
if (%_IsConstructCall()) {
try { captureStackTrace(this, f); } catch (e) { }
« no previous file with comments | « no previous file | test/mjsunit/get-prototype-of.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698