on master help sign in
Say the operator name in RHS type errors

Doing the suggestion from https://github.com/elm-lang/error-message-catalog/issues/155

commit704f7265b86f20180cb95e61344dc74f929b88cb authorEvan Czaplicki <evancz@users.noreply.github.com> dateWed 26 Oct 2016, 17:00 (10 years ago) parentcef671f
1 file changed+4−3
src/Reporting/Error/Type.hs+4−3
src/Reporting/Error/Type.hs+4−3
@@ -10,6 +10,7 @@ import Text.PrettyPrint.ANSI.Leijen
1010 , fillSep, indent, text, underline, vcat
1111 )
1212
13+import qualified AST.Helpers as Help
1314import qualified AST.Type as Type
1415import qualified AST.Variable as Var
1516import qualified Reporting.Error.Helpers as Help
@@ -274,9 +275,9 @@ mismatchToReport localizer (MismatchInfo hint leftType rightType maybeReason) =
274275 "But the right side is:"
275276 ( binopHint op leftType rightType
276277 ++
277− [ "With binary operations, I always figure out the left side first. If it\
278− \ seems fine, I assume it is \"correct\" in subsequent checks.\
279− \ So the problem may actually be in how the left and right arguments interact."
278+ [ "With operators like " ++ prettyName op ++ " I always check the left\
279+ \ side first. If it seems fine, I assume it is correct and check the right\
280+ \ side. So the problem may be in how the left and right arguments interact."
280281 ]
281282 )
282283 )