Remove unnecessary lifted functions, capture rename function. Passes all tests

Capture function: Rename variables bound in lets so that variables
won't be camptured when lets are lifted