New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[OCaml] Typechecking limitation in presence of mutually recursive modules #7077
Comments
Comment author: @garrigue Since there is no specification for recursive modules, there are no bugs :-) |
This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc. |
Still repros FWIW. Do I understand correctly that this is an instance of classic "double-vision"? |
This is worse than double-vision. In normal double-vision issues the compiler is not aware that a type and the same type accessed via recursion are the same. Here, we are getting some kind of principality failure because the type-checker is treating two types that are known to equal differently. |
This issue has been open one year with no activity. Consequently, it is being marked with the "stale" label. What this means is that the issue will be automatically closed in 30 days unless more comments are added or the "stale" label is removed. Comments that provide new information on the issue are especially welcome: is it still reproducible? did it appear in other contexts? how critical is it? etc. |
Original bug ID: 7077
Reporter: Iguernlala
Status: acknowledged (set by @damiendoligez on 2016-02-03T16:20:16Z)
Resolution: open
Priority: normal
Severity: feature
Version: 4.02.3
Target version: undecided
Category: typing
Tags: recmod
Bug description
The attached code does not typecheck unless type annotation is
put on line "L29", or lines "L29" and "L30" are swapped.
Maybe the information which says that "Th.term" and "term" are
equal is lost when comparing module's inferred signature with the
required one (?). Compiling with "-short-paths" to choose "term"
as a representative of "Th.term" does not resolve the problem.
File attachments
The text was updated successfully, but these errors were encountered: