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

Unified Diff: src/ast.h

Issue 4004006: Fix a bug that prevents constants from overwriting function values in object ... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 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
Index: src/ast.h
===================================================================
--- src/ast.h (revision 5712)
+++ src/ast.h (working copy)
@@ -832,10 +832,14 @@
bool IsCompileTimeValue();
+ void set_emit_store(bool emit_store);
+ bool emit_store();
+
private:
Literal* key_;
Expression* value_;
Kind kind_;
+ bool emit_store_;
};
ObjectLiteral(Handle<FixedArray> constant_properties,
@@ -858,6 +862,12 @@
bool fast_elements() const { return fast_elements_; }
+
+ // Mark all computed expressions that are bound to a key that
+ // is shadowed by a later occurrence of the same key. For the
+ // marked expressions, no store code is emitted.
+ void CalculateEmitStore();
+
private:
Handle<FixedArray> constant_properties_;
ZoneList<Property*>* properties_;
« no previous file with comments | « src/arm/full-codegen-arm.cc ('k') | src/ast.cc » ('j') | src/ia32/full-codegen-ia32.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698