Skip to content

Commit

Permalink
De-prioritize singleton chunks when we know none of them definitely fits
Browse files Browse the repository at this point in the history
  • Loading branch information
marcoeilers committed Sep 11, 2023
1 parent 8c0b2d2 commit 9b62b97
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/scala/rules/QuantifiedChunkSupport.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1761,7 +1761,9 @@ object quantifiedChunkSupporter extends QuantifiedChunkSupport {
if (greedyMatch.nonEmpty) {
greedyMatch ++ chunks.diff(greedyMatch)
} else {
fallback(chunks)
// It doesn't seem to be any of the singletons. Use the fallback on the non-singletons.
val (qpChunks, singletons) = chunks.partition(_.singletonArguments.isEmpty)
fallback(qpChunks) ++ singletons
}
}
}
Expand Down

0 comments on commit 9b62b97

Please sign in to comment.