Improve error messages from argument checking