Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
suboptimal error message #7663
Original bug ID: 7663
At some point, when I was trying to compile my program, I got this error message:
Error: Cannot safely evaluate the definition
Unless the user read Section 7.4 of the reference manual
Since this topic is subtle (one needs to understand what implementors of Ocaml mean by "safe module" and that this is (somehow) closely related to "safe evaluation" so I think it would make sense if the error message referred the user for further information to the corresponding place (Section 7.4 of the User's Manual).
It would be very helpful if Section 7.4 showed:
The most trivial situation I was able to trigger the error (which confused me completely) is this:
module rec M1 :
and M2 :
It would be illustrative to show the necessary workaround that enables one to compile programs like these.
Please consider this as a subjective feedback as this is not really a rigorous area. I am curious what do you think.