Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Flow analysis is not available outside of function bodies and initial…
…izers. This fixes a group of crashes during fuzz testing. FAILURE: typedef`(=<?[ [NoSuchMethodError: The method 'nullAwareAccess_rightBegin' was called on null. Receiver: null Tried calling: nullAwareAccess_rightBegin(Instance of 'ListLiteralImpl', Instance of 'InterfaceTypeImpl'), #0 Object.noSuchMethod (dart:core-patch/object_patch.dart:54:5) flutter#1 ResolverVisitor.startNullAwareIndexExpression (package:analyzer/src/generated/resolver.dart:776:26) flutter#2 ResolverVisitor.visitIndexExpression (package:analyzer/src/generated/resolver.dart:1585:5) flutter#3 IndexExpressionImpl.accept (package:analyzer/src/dart/ast/ast.dart:5993:49) flutter#4 DefaultFormalParameterImpl.visitChildren (package:analyzer/src/dart/ast/ast.dart:3008:20) #5 ResolverVisitor.visitNode (package:analyzer/src/generated/resolver.dart:1743:10) flutter#6 UnifyingAstVisitor.visitDefaultFormalParameter (package:analyzer/dart/ast/visitor.dart:3198:65) flutter#7 ResolverVisitor.visitDefaultFormalParameter (package:analyzer/src/generated/resolver.dart:1239:11) flutter#8 DefaultFormalParameterImpl.accept (package:analyzer/src/dart/ast/ast.dart:3003:15) flutter#9 NodeListImpl.accept (package:analyzer/src/dart/ast/ast.dart:7611:20) flutter#10 FormalParameterListImpl.visitChildren (package:analyzer/src/dart/ast/ast.dart:4493:17) flutter#11 ResolverVisitor.visitNode (package:analyzer/src/generated/resolver.dart:1743:10) flutter#12 UnifyingAstVisitor.visitFormalParameterList (package:analyzer/dart/ast/visitor.dart:3258:59) flutter#13 ScopedVisitor.visitFormalParameterList (package:analyzer/src/generated/resolver.dart:2717:11) flutter#14 FormalParameterListImpl.accept (package:analyzer/src/dart/ast/ast.dart:4489:49) flutter#15 FunctionTypeAliasImpl.visitChildren (package:analyzer/src/dart/ast/ast.dart:5166:18) flutter#16 ResolverVisitor.visitNode (package:analyzer/src/generated/resolver.dart:1743:10) flutter#17 UnifyingAstVisitor.visitFunctionTypeAlias (package:analyzer/dart/ast/visitor.dart:3285:55) flutter#18 ScopedVisitor.visitFunctionTypeAliasInScope (package:analyzer/src/generated/resolver.dart:2819:11) flutter#19 ResolverVisitor.visitFunctionTypeAliasInScope (package:analyzer/src/generated/resolver.dart:1490:11) flutter#20 ScopedVisitor.visitFunctionTypeAlias (package:analyzer/src/generated/resolver.dart:2812:7) #21 ResolverVisitor.visitFunctionTypeAlias (package:analyzer/src/generated/resolver.dart:1482:13) #22 FunctionTypeAliasImpl.accept (package:analyzer/src/dart/ast/ast.dart:5158:49) #23 ResolverVisitor.visitCompilationUnit (package:analyzer/src/generated/resolver.dart:1088:23) #24 CompilationUnitImpl.accept (package:analyzer/src/dart/ast/ast.dart:2134:49) #25 LibraryAnalyzer._resolveFile (package:analyzer/src/dart/analysis/library_analyzer.dart:706:10) Continues //dart-review.googlesource.com/c/sdk/+/175187 Change-Id: I9518363961b4adcf7f57c2f0661151ef74efc2f5 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/175906 Reviewed-by: Brian Wilkerson <brianwilkerson@google.com> Reviewed-by: Samuel Rawlins <srawlins@google.com> Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
- Loading branch information