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

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

Issue 1968263002: Remove unused 'receiver' field from generators (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: weaken dcheck Created 4 years, 7 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-debug.cc ('k') | src/x64/builtins-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime/runtime-generator.cc
diff --git a/src/runtime/runtime-generator.cc b/src/runtime/runtime-generator.cc
index 91766394522412a25939b16d4221287e22f52e73..c81895a177ea2ec6a35187e38f88523a4cad6453 100644
--- a/src/runtime/runtime-generator.cc
+++ b/src/runtime/runtime-generator.cc
@@ -14,9 +14,8 @@ namespace internal {
RUNTIME_FUNCTION(Runtime_CreateJSGeneratorObject) {
HandleScope scope(isolate);
- DCHECK(args.length() == 2);
+ DCHECK(args.length() == 1);
CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 0);
- CONVERT_ARG_HANDLE_CHECKED(Object, receiver, 1);
RUNTIME_ASSERT(function->shared()->is_generator());
Handle<FixedArray> operand_stack;
@@ -32,7 +31,6 @@ RUNTIME_FUNCTION(Runtime_CreateJSGeneratorObject) {
isolate->factory()->NewJSGeneratorObject(function);
generator->set_function(*function);
generator->set_context(isolate->context());
- generator->set_receiver(*receiver);
generator->set_operand_stack(*operand_stack);
generator->set_continuation(JSGeneratorObject::kGeneratorExecuting);
return *generator;
@@ -99,16 +97,6 @@ RUNTIME_FUNCTION(Runtime_GeneratorGetFunction) {
}
-// Returns receiver of generator activation.
-RUNTIME_FUNCTION(Runtime_GeneratorGetReceiver) {
- HandleScope scope(isolate);
- DCHECK(args.length() == 1);
- CONVERT_ARG_HANDLE_CHECKED(JSGeneratorObject, generator, 0);
-
- return generator->receiver();
-}
-
-
// Returns input of generator activation.
RUNTIME_FUNCTION(Runtime_GeneratorGetInput) {
HandleScope scope(isolate);
« no previous file with comments | « src/runtime/runtime-debug.cc ('k') | src/x64/builtins-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698