lix/doc/manual/rl-next/print-value-in-type-error.md
eldritch horrors 87e6ac5eb7 Merge pull request #9753 from 9999years/print-value-on-type-error
Print the value in `value is X while a Y is expected` error

(cherry picked from commit 5f72a97092da6af28a7d2b2a50d74e9d34fae7e1)
Change-Id: Idb4bc903ae59a0f5b6fb3b1da4d47970fe0a6efe
2024-03-09 00:05:41 -07:00

605 B

synopsis issues prs
Type errors include the failing value

In errors like value is an integer while a list was expected, the message now includes the failing value.

Before:

       error: value is a set while a string was expected

After:

       error: expected a string but found a set: { ghc810 = «thunk»;
       ghc8102Binary = «thunk»; ghc8107 = «thunk»; ghc8107Binary = «thunk»;
       ghc865Binary = «thunk»; ghc90 = «thunk»; ghc902 = «thunk»; ghc92 = «thunk»;
       ghc924Binary = «thunk»; ghc925 = «thunk»;  «17 attributes elided»}