Closed shym closed 1 year ago
The message Symbol not found is used in many cases, some of which I find rather hostile to newcomers.
Symbol not found
On the following example:
(*@ val g: int -> int *) val f : int -> int (*@ r = f x ensures r = g x *)
gospel check reports:
gospel check
File "abc.mli", line 5, characters 16-17: 5 | ensures r = g x *) ^ Error: Symbol g not found.
This is due to the fact that g was not declared as pure.
g
pure
The same message is used for r in the following:
r
val f : int -> int (*@ r = f x requires r = 0 *)
where the result is bound in a requires.
requires
Maybe specific messages should be used in those cases to help users understand what is in scope.
I would propose to reformulate the symbol-not-found error message so that it refers users to that part of the documentation.
The message
Symbol not found
is used in many cases, some of which I find rather hostile to newcomers.On the following example:
gospel check
reports:This is due to the fact that
g
was not declared aspure
.The same message is used for
r
in the following:where the result is bound in a
requires
.Maybe specific messages should be used in those cases to help users understand what is in scope.