Refactor one of the larger functions for Type Diffing into smaller functions.
No functionality change.