Added logic from constant-lifting to free variables visitor (commented out for now).