Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiler Failed #43290

Closed
lyetor opened this issue Sep 2, 2020 · 1 comment
Closed

Compiler Failed #43290

lyetor opened this issue Sep 2, 2020 · 1 comment
Assignees
Labels
area-front-end Use area-front-end for front end / CFE / kernel format related issues.

Comments

@lyetor
Copy link

lyetor commented Sep 2, 2020

OS: Ubuntu 16.04

Dart SDK build number: 2.10.0-edge.24c7666def53832a31559beac130eb3336008110
The compiler crashed: Unsupported operation: Unhandled node InvalidExpression(<invalid:Instance field
access outside constructor>) (InvalidExpression)
#0      ScopeModelBuilder.defaultNode (package:compiler/src/ir/scope_visitor.dart:123:7)
#1      Visitor.defaultTreeNode (package:kernel/visitor.dart:523:39)
#2      TreeVisitor.defaultExpression (package:kernel/visitor.dart:144:43)
#3      TreeVisitor.visitInvalidExpression (package:kernel/visitor.dart:146:55)
#4      InvalidExpression.accept (package:kernel/ast.dart:3069:44)
#5      ScopeModelBuilder.visitNode (package:compiler/src/ir/scope_visitor.dart:126:18)
#6      ScopeModelBuilder.visitNamedExpression (package:compiler/src/ir/scope_visitor.dart:215:12)
#7      NamedExpression.accept (package:kernel/ast.dart:3813:38)
#8      ScopeModelBuilder.visitNode (package:compiler/src/ir/scope_visitor.dart:126:18)
#9      ScopeModelBuilder.visitNodes (package:compiler/src/ir/scope_visitor.dart:132:39)
#10     ScopeModelBuilder.visitConstructorInvocation
(package:compiler/src/ir/scope_visitor.dart:872:5)
#11     ConstructorInvocation.accept (package:kernel/ast.dart:4154:44)
#12     ScopeModelBuilder.visitNode (package:compiler/src/ir/scope_visitor.dart:126:18)
#13     ScopeModelBuilder.visitReturnStatement (package:compiler/src/ir/scope_visitor.dart:1004:5)
#14     ReturnStatement.accept (package:kernel/ast.dart:6491:43)
#15     ScopeModelBuilder.visitNode (package:compiler/src/ir/scope_visitor.dart:126:18)
#16     ScopeModelBuilder.visitNodes (package:compiler/src/ir/scope_visitor.dart:132:39)
#17     ScopeModelBuilder.visitBlock (package:compiler/src/ir/scope_visitor.dart:989:5)
#18     Block.accept (package:kernel/ast.dart:5823:43)
#19     ScopeModelBuilder.visitNode (package:compiler/src/ir/scope_visitor.dart:126:18)
#20     ScopeModelBuilder.visitFunctionNode (package:compiler/src/ir/scope_visitor.dart:747:5)
#21     FunctionNode.accept (package:kernel/ast.dart:2909:38)
#22     ScopeModelBuilder.visitNode (package:compiler/src/ir/scope_visitor.dart:126:18)
#23     ScopeModelBuilder.visitProcedure.<anonymous closure>
(package:compiler/src/ir/scope_visitor.dart:590:7)
#24     ScopeModelBuilder.enterNewScope (package:compiler/src/ir/scope_visitor.dart:207:18)
#25     ScopeModelBuilder.visitInvokable (package:compiler/src/ir/scope_visitor.dart:518:5)
#26     ScopeModelBuilder.visitProcedure (package:compiler/src/ir/scope_visitor.dart:589:5)
#27     Procedure.accept (package:kernel/ast.dart:2400:40)
#28     ScopeModelBuilder.computeModel (package:compiler/src/ir/scope_visitor.dart:113:12)
#29     new ScopeModel.from (package:compiler/src/ir/scope.dart:26:20)
#30     KernelModularStrategy.getModularMemberData.<anonymous closure>
(package:compiler/src/kernel/kernel_strategy.dart:443:19)
#31     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#32     KernelModularStrategy.getModularMemberData
(package:compiler/src/kernel/kernel_strategy.dart:442:43)
#33     KernelWorkItem.run.<anonymous closure>
(package:compiler/src/kernel/kernel_strategy.dart:392:28)
#34     CompilerTask.measure (package:compiler/src/common/tasks.dart:64:51)
#35     KernelWorkItem.run (package:compiler/src/kernel/kernel_strategy.dart:377:26)
#36     Compiler.emptyQueue.<anonymous closure>.<anonymous closure>.<anonymous closure>.<anonymous
closure>.<anonymous closure> (package:compiler/src/compiler.dart:462:70)
#37     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#38     Compiler.emptyQueue.<anonymous closure>.<anonymous closure>.<anonymous closure>.<anonymous
closure> (package:compiler/src/compiler.dart:462:32)
#39     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#40     Compiler.emptyQueue.<anonymous closure>.<anonymous closure>.<anonymous closure>
(package:compiler/src/compiler.dart:460:28)
#41     CompilerDiagnosticReporter.withCurrentElement (package:compiler/src/compiler.dart:745:15)
#42     Compiler.emptyQueue.<anonymous closure>.<anonymous closure>
(package:compiler/src/compiler.dart:458:18)
#43     ResolutionEnqueuer._forEach (package:compiler/src/enqueue.dart:449:12)
#44     ResolutionEnqueuer.forEach (package:compiler/src/enqueue.dart:465:5)
#45     Compiler.emptyQueue.<anonymous closure> (package:compiler/src/compiler.dart:454:16)
#46     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#47     Compiler.emptyQueue (package:compiler/src/compiler.dart:453:14)
#48     Compiler.processQueue.<anonymous closure> (package:compiler/src/compiler.dart:479:7)
#49     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#50     Compiler.processQueue (package:compiler/src/compiler.dart:472:14)
#51     Compiler.computeClosedWorld (package:compiler/src/compiler.dart:341:5)
#52     Compiler.compileFromKernel.<anonymous closure>.<anonymous closure>
(package:compiler/src/compiler.dart:409:17)
#53     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#54     Compiler.compileFromKernel.<anonymous closure> (package:compiler/src/compiler.dart:408:43)
#55     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#56     Compiler.compileFromKernel (package:compiler/src/compiler.dart:407:14)
#57     Compiler.runInternal (package:compiler/src/compiler.dart:259:13)
<asynchronous suspension>
#58     Compiler.run.<anonymous closure>.<anonymous closure>
(package:compiler/src/compiler.dart:214:38)
#59     new Future.sync (dart:async/future.dart:223:31)
#60     Compiler.run.<anonymous closure> (package:compiler/src/compiler.dart:214:20)
#61     CompilerTask.measureSubtask (package:compiler/src/common/tasks.dart:179:35)
#62     Compiler.run (package:compiler/src/compiler.dart:211:41)
#63     CompilerImpl.run.<anonymous closure>.<anonymous closure>
(package:compiler/src/apiimpl.dart:91:22)
#64     _RootZone.runUnary (dart:async/zone.dart:1450:54)
#65     _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
#66     Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
#67     Future._propagateToListeners (dart:async/future_impl.dart:725:32)
#68     Future._completeWithValue (dart:async/future_impl.dart:529:5)
#69     Future._asyncCompleteWithValue.<anonymous closure> (dart:async/future_impl.dart:567:7)
#70     _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#71     _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#72     _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13)
#73     _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:169:5)
@mraleph mraleph added the area-front-end Use area-front-end for front end / CFE / kernel format related issues. label Sep 2, 2020
@johnniwinther
Copy link
Member

Repro:

class Class {
  final int length;
  
  const Class({this.length});

  method() {
    const Class(length: this.length);
  }
}

main() {
  new Class().method();
}

@johnniwinther johnniwinther self-assigned this Sep 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-front-end Use area-front-end for front end / CFE / kernel format related issues.
Projects
None yet
Development

No branches or pull requests

3 participants