diff --git a/lib/src/transformer/declaration_parsing.dart b/lib/src/transformer/declaration_parsing.dart index aa66f0fd6..28fefaad2 100644 --- a/lib/src/transformer/declaration_parsing.dart +++ b/lib/src/transformer/declaration_parsing.dart @@ -171,7 +171,7 @@ class ParsedDeclarations { } } - if (noneOfAnyRequiredDecl && declarations.length != 0) { + if (noneOfAnyRequiredDecl && declarations.isNotEmpty) { error( 'To define a component, a `@$annotationName` must be accompanied by ' 'the following annotations within the same file: '