Improve error messages from type-checking data constructors