mirror of
https://github.com/dart-lang/sdk
synced 2024-09-15 22:19:49 +00:00
[dart2wasm] Fix block type of unimplemented
The test co19/Language/Libraries_and_Scripts/Imports/static_type_t01 now fails with "unreachable" in runtime as expected (instead of compile time crash). Change-Id: Ia311485b3eefcde2d07d67b473238129dad69cce Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/263580 Reviewed-by: Aske Simon Christensen <askesc@google.com> Commit-Queue: Ömer Ağacan <omersa@google.com>
This commit is contained in:
parent
48f33cc37a
commit
bc46593d5d
|
@ -125,7 +125,8 @@ class CodeGenerator extends ExpressionVisitor1<w.ValueType, w.ValueType>
|
|||
|
||||
@override
|
||||
w.ValueType defaultExpression(Expression node, w.ValueType expectedType) {
|
||||
unimplemented(node, node.runtimeType, [expectedType]);
|
||||
unimplemented(
|
||||
node, node.runtimeType, [if (expectedType != voidMarker) expectedType]);
|
||||
return expectedType;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue