Move syntax lifting helper to a new file in TR
Support lifts in TR with-types

Closes PR 14650
Fix cast/make-predicate contracts in with-type
Refactor and organize imports