[backport] transformers no longer ignore UnApply.fun

Backports 7122560063 and 4133eb8454 from the 2.11.x branch