roc/compiler/solve
ayazhafiz ee34e79790 Include annotation type signatures in Expected struct
To provide better error messages and suggestions related to changing
type annotations, we now pass annotation type signatures all the way
down through the constraint solver. At constraint generation we
associate the type signature with a unique variable, and during error
reporting, we pull out an `ErrorType` corresponding to the original type
signature, by looking up the unique variable. This gives us two nice
things:

1. It means we don't have to pass the original, AST-like type
   annotation, which can be quite large, to everyone who looks at an
   expectation.
2. It gives us a translation from a `Type` to an `ErrorType` for free
   using the existing translation procedure in `roc_types::subs`,
   without having to create a new translation function.
2021-11-25 11:16:17 -05:00
..
src Include annotation type signatures in Expected struct 2021-11-25 11:16:17 -05:00
tests Add support for type inference at _s in type definitions 2021-11-21 22:54:45 -05:00
Cargo.toml bumpalo type_to_var 2021-11-19 19:48:51 +01:00