on master help sign in
Show correct record update message when it is a type alias
11c9e15Evan Czaplicki
compiler/src/Reporting/Error/Type.hs+3−3
@@ -977,7 +977,7 @@ toExprReport source localizer exprRegion category tipe expected =
977 )
977 )
978
978
979 RecordUpdate ->
979 RecordUpdate ->
980− case tipe of
980+ case T.iteratedDealias tipe of
981 T.Record _ _ ->
981 T.Record _ _ ->
982 Report.toCodeSnippet source region Nothing $
982 Report.toCodeSnippet source region Nothing $
983 (
983 (
@@ -1746,8 +1746,8 @@ toInfiniteReport source localizer region name overallType =
1746 \ parts of the type that repeat something already printed out infinitely."
1746 \ parts of the type that repeat something already printed out infinitely."
1747 , D.indent 4 (D.dullyellow (T.toDoc localizer RT.None overallType))
1747 , D.indent 4 (D.dullyellow (T.toDoc localizer RT.None overallType))
1748 , D.reflowLink
1748 , D.reflowLink
1749− "Staring at the type is usually not so helpful, so I recommend reading the hints at"
1749+ "Staring at this type is usually not so helpful, so I recommend reading the hints at"
1750 "infinite-type"
1750 "infinite-type"
1751− "to get unstuck."
1751+ "to get unstuck!"
1752 ]
1752 ]
1753 )
1753 )