Improves parentheses variable handling