| Index: runtime/vm/object_reload.cc
|
| diff --git a/runtime/vm/object_reload.cc b/runtime/vm/object_reload.cc
|
| index f3b06e0da26669dc82984adeb761b7dabc6f1db6..0429adfcff87cf511223b620800fe736faf5ae5a 100644
|
| --- a/runtime/vm/object_reload.cc
|
| +++ b/runtime/vm/object_reload.cc
|
| @@ -128,7 +128,9 @@ void Class::CopyStaticFieldValues(const Class& old_cls) const {
|
| old_field = Field::RawCast(old_field_list.At(j));
|
| old_name = old_field.name();
|
| if (name.Equals(old_name)) {
|
| - if (update_values) {
|
| + // We only copy values if requested and if the field is not a const
|
| + // field. We let const fields be updated with a reload.
|
| + if (update_values && !field.is_const()) {
|
| value = old_field.StaticValue();
|
| field.SetStaticValue(value);
|
| }
|
|
|