As suggested post-commit for a0022719, unswitch the condition in replaceUsesWithIf to simplify the check.