Cleaning up variable argument discovery logic