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

Unified Diff: runtime/vm/object_reload.cc

Issue 2142013002: Fix language/enum* hot reload failures (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 5 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object_reload.cc
diff --git a/runtime/vm/object_reload.cc b/runtime/vm/object_reload.cc
index f9c5ad9869e4fffd1c825f305413977bfb0a8bb2..3e52226005cff8cd1f52e387866b48e4ac56ec96 100644
--- a/runtime/vm/object_reload.cc
+++ b/runtime/vm/object_reload.cc
@@ -220,7 +220,7 @@ void Class::ReplaceEnum(const Class& old_enum) const {
// Grab 'values' from |old_enum|.
const Field& old_enum_values_field = Field::Handle(
- old_enum.LookupStaticField(Symbols::Values()));
+ old_enum.LookupStaticFieldAllowPrivate(Symbols::Values()));
ASSERT(!old_enum_values_field.IsNull());
const Array& old_enum_values =
Array::Handle(Array::RawCast(old_enum_values_field.StaticValue()));
@@ -236,7 +236,7 @@ void Class::ReplaceEnum(const Class& old_enum) const {
// Grab values from |this|.
const Field& enum_values_field = Field::Handle(
- LookupStaticField(Symbols::Values()));
+ LookupStaticFieldAllowPrivate(Symbols::Values()));
ASSERT(!enum_values_field.IsNull());
Array& enum_values =
Array::Handle(Array::RawCast(enum_values_field.StaticValue()));
@@ -290,7 +290,7 @@ void Class::ReplaceEnum(const Class& old_enum) const {
enum_class_name.Length() + 1);
ASSERT(!enum_field_name.IsNull());
// Grab the static field.
- enum_field = LookupStaticField(enum_field_name);
+ enum_field = LookupStaticFieldAllowPrivate(enum_field_name);
ASSERT(!enum_field.IsNull());
// Use old value with updated index.
enum_field.SetStaticValue(Instance::Cast(enum_value), true);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698