| Index: pkg/analyzer/lib/src/generated/parser.dart
|
| diff --git a/pkg/analyzer/lib/src/generated/parser.dart b/pkg/analyzer/lib/src/generated/parser.dart
|
| index 2e5bca214d79e8ecb542d8ad8eb44e24ea7f385f..29974682eaaa61b81bd3fb6ff3e4a24a9d367556 100644
|
| --- a/pkg/analyzer/lib/src/generated/parser.dart
|
| +++ b/pkg/analyzer/lib/src/generated/parser.dart
|
| @@ -5066,7 +5066,9 @@ class Parser {
|
| externalKeyword == null) {
|
| _reportErrorForToken(ParserErrorCode.CONST_FACTORY, factoryKeyword);
|
| } else if (body is EmptyFunctionBody) {
|
| - if (factoryKeyword != null && externalKeyword == null) {
|
| + if (factoryKeyword != null &&
|
| + externalKeyword == null &&
|
| + _parseFunctionBodies) {
|
| _reportErrorForToken(
|
| ParserErrorCode.FACTORY_WITHOUT_BODY, factoryKeyword);
|
| }
|
|
|