rescript-compiler
rescript-compiler copied to clipboard
Better error message for missing methods on objects
They are called fields in docs. I think we should call them fields in errors too. for example. This error
This expression has type user, it has no method lastName
should be
This expression has type user, it has no field lastName
Looks like it only need to modify these two lines, Am I right? https://github.com/rescript-lang/syntax/blob/master/compiler-libs-406/typecore.ml#L4985 https://github.com/rescript-lang/syntax/blob/master/compiler-libs-406/typecore.ml#L4991
In the rescript-compiler repo not here.
I think this can be closed. These messages no longer read like that in master.