| Index: pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart
|
| diff --git a/pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart b/pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart
|
| index acb5b91637f0d846bebfd8cf728a91f9dc3a33fb..298a0827b70efffc4657f8ff346733bd0817003f 100644
|
| --- a/pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart
|
| +++ b/pkg/compiler/lib/src/cps_ir/shrinking_reductions.dart
|
| @@ -545,11 +545,15 @@ bool _isUselessIf(Branch branch) {
|
| falseInvoke.continuation.definition) {
|
| return false;
|
| }
|
| - assert(trueInvoke.arguments.length == falseInvoke.arguments.length);
|
| // Matching zero arguments should be adequate, since isomorphic true and false
|
| // invocations should result in redundant phis which are removed elsewhere.
|
| - if (trueInvoke.arguments.isNotEmpty) return false;
|
| - return true;
|
| + //
|
| + // Note that the argument lists are not necessarily the same length here,
|
| + // because we could be looking for new redexes in the middle of performing a
|
| + // dead parameter reduction, where some but not all of the invocations have
|
| + // been rewritten. In that case, we will find the redex (once) after both
|
| + // of these invocations have been rewritten.
|
| + return trueInvoke.arguments.isEmpty && falseInvoke.arguments.isEmpty;
|
| }
|
|
|
| bool _isDeadParameter(Parameter parameter) {
|
|
|