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

Unified Diff: src/hydrogen.cc

Issue 534093003: Fix loading non-configurable non-writable value from a constant with mismatching type feedback (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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 | « no previous file | src/hydrogen-instructions.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 169df22aa8293093add0c5275fb7343b00118c6e..1de83c5d380f7349a3c4468874fbf856958c0361 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -5792,16 +5792,16 @@ HInstruction* HOptimizedGraphBuilder::BuildLoadNamedField(
PropertyAccessInfo* info,
HValue* checked_object) {
// See if this is a load for an immutable property
- if (checked_object->ActualValue()->IsConstant() && info->IsReadOnly() &&
- !info->IsConfigurable()) {
+ if (checked_object->ActualValue()->IsConstant()) {
Handle<Object> object(
HConstant::cast(checked_object->ActualValue())->handle(isolate()));
if (object->IsJSObject()) {
LookupIterator it(object, info->name(), LookupIterator::OWN_PROPERTY);
Handle<Object> value = JSObject::GetDataProperty(&it);
- CHECK(it.IsFound());
- return New<HConstant>(value);
+ if (it.IsFound() && it.IsReadOnly() && !it.IsConfigurable()) {
+ return New<HConstant>(value);
+ }
}
}
« no previous file with comments | « no previous file | src/hydrogen-instructions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698