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

Unified Diff: src/runtime/runtime-internal.cc

Issue 2825123002: Revert of [errors] Improve NotGeneric error message (Closed)
Patch Set: Created 3 years, 8 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/runtime/runtime.h ('k') | test/mjsunit/messages.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime/runtime-internal.cc
diff --git a/src/runtime/runtime-internal.cc b/src/runtime/runtime-internal.cc
index 7348d5f007198f212bc347e0e9e28b1762580669..3a51c0a0c15e125b0b03c913f6dc9462fd7db1c0 100644
--- a/src/runtime/runtime-internal.cc
+++ b/src/runtime/runtime-internal.cc
@@ -286,6 +286,14 @@
CONVERT_ARG_HANDLE_CHECKED(Object, object, 0);
THROW_NEW_ERROR_RETURN_FAILURE(
isolate, NewTypeError(MessageTemplate::kNotConstructor, object));
+}
+
+RUNTIME_FUNCTION(Runtime_ThrowNotGeneric) {
+ HandleScope scope(isolate);
+ DCHECK_EQ(1, args.length());
+ CONVERT_ARG_HANDLE_CHECKED(Object, arg0, 0);
+ THROW_NEW_ERROR_RETURN_FAILURE(
+ isolate, NewTypeError(MessageTemplate::kNotGeneric, arg0));
}
RUNTIME_FUNCTION(Runtime_ThrowGeneratorRunning) {
« no previous file with comments | « src/runtime/runtime.h ('k') | test/mjsunit/messages.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698