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

Unified Diff: src/compiler.cc

Issue 546006: Some cleanup of the toplevel code generator:... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 years, 11 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/compiler.cc
===================================================================
--- src/compiler.cc (revision 3576)
+++ src/compiler.cc (working copy)
@@ -902,11 +902,7 @@
// We will only visit the key during code generation for keyed property
// stores. Leave its expression context uninitialized for named
// property stores.
- Literal* lit = prop->key()->AsLiteral();
- uint32_t ignored;
- if (lit == NULL ||
- !lit->handle()->IsSymbol() ||
- String::cast(*(lit->handle()))->AsArrayIndex(&ignored)) {
+ if (!prop->key()->IsPropertyName()) {
ProcessExpression(prop->key(), Expression::kValue);
CHECK_BAILOUT;
}
@@ -1030,11 +1026,7 @@
// We will only visit the key during code generation for keyed property
// stores. Leave its expression context uninitialized for named
// property stores.
- Literal* lit = prop->key()->AsLiteral();
- uint32_t ignored;
- if (lit == NULL ||
- !lit->handle()->IsSymbol() ||
- String::cast(*(lit->handle()))->AsArrayIndex(&ignored)) {
+ if (!prop->key()->IsPropertyName()) {
ProcessExpression(prop->key(), Expression::kValue);
CHECK_BAILOUT;
}

Powered by Google App Engine
This is Rietveld 408576698