| Index: runtime/vm/parser.cc
|
| diff --git a/runtime/vm/parser.cc b/runtime/vm/parser.cc
|
| index 3dc9370481d463c84d6f8361e2968c63e84f7bcb..c7b2b8d509532e16e333db4f4b41fe96b6659ac5 100644
|
| --- a/runtime/vm/parser.cc
|
| +++ b/runtime/vm/parser.cc
|
| @@ -5970,7 +5970,9 @@ void Parser::ParseTopLevel() {
|
| }
|
| }
|
| }
|
| - if ((top_level.fields.Length() > 0) || (top_level.functions.Length() > 0)) {
|
| +
|
| + if ((library_.num_anonymous_classes() == 0) ||
|
| + (top_level.fields.Length() > 0) || (top_level.functions.Length() > 0)) {
|
| toplevel_class.AddFields(top_level.fields);
|
|
|
| const Array& array = Array::Handle(Z,
|
|
|