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

Unified Diff: src/full-codegen.h

Issue 718473002: ES6: Add support for super in object literals (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix remaining code review issues Created 6 years, 1 month 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/ast.cc ('k') | src/hydrogen.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/full-codegen.h
diff --git a/src/full-codegen.h b/src/full-codegen.h
index f0328547fde7d36b96449e31a106036f65e46363..fd53ceaf613aaeed26e39e39a7bd1b6812a4906f 100644
--- a/src/full-codegen.h
+++ b/src/full-codegen.h
@@ -614,6 +614,15 @@ class FullCodeGenerator: public AstVisitor {
void EmitLoadHomeObject(SuperReference* expr);
+ static bool NeedsHomeObject(Expression* expr) {
+ return FunctionLiteral::NeedsHomeObject(expr);
+ }
+
+ // Adds the [[HomeObject]] to |initializer| if it is a FunctionLiteral.
+ // The value of the initializer is expected to be at the top of the stack.
+ // |offset| is the offset in the stack where the home object can be found.
+ void EmitSetHomeObjectIfNeeded(Expression* initializer, int offset);
+
void EmitLoadSuperConstructor(SuperReference* expr);
void CallIC(Handle<Code> code,
« no previous file with comments | « src/ast.cc ('k') | src/hydrogen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698