generate functions for split-out code
add variable info to outlined functions