Ensure that polymorphic conditionals are treated as a unit.

Fixes #16983.