better semicolon handling