| Anonymous | Login | Signup for a new account | 2013-05-21 11:10 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | |||
| 0002737 | OCaml | OCaml general | public | 2004-06-17 02:44 | 2012-01-30 15:09 | |||
| Reporter | administrator | |||||||
| Assigned To | ||||||||
| Priority | normal | Severity | feature | Reproducibility | always | |||
| Status | closed | Resolution | fixed | |||||
| Platform | OS | OS Version | ||||||
| Product Version | ||||||||
| Target Version | Fixed in Version | 3.12.0 | ||||||
| Summary | 0002737: sig_of_struct | |||||||
| Description | Full_Name: Evgeny Chukreev Version: OS: Submission from: 81.176.98.115 (81.176.98.115) Feature wish: It's impossible now to write code like: module B = struct (* blah-blah-blah *) end module type A = sig (* blah-blah-blah *) include (sig_of_struct B) end | |||||||
| Tags | No tags attached. | |||||||
| Attached Files | ||||||||
Notes |
|
|
(0000225) administrator (administrator) 2004-06-17 10:16 |
> Full_Name: Evgeny Chukreev > > Feature wish: > It's impossible now to write code like: > > module B = > struct > (* blah-blah-blah *) > end > > module type A = > sig > (* blah-blah-blah *) > > include (sig_of_struct B) > end This is also a feature I would like to have. However, there is a small "moral" problem: as the signature of B is not given explicitly, you are relying on the type checker to produce, and it could be for instance more general than you expected. I.e. a function may be more polymorphic than expected, and as a result the signature produced would be incompatible with the expected one. I don't see it as a major problem, but it may be a religious issue for some. On the other hand, it should be possible at least to have a weaker feature: have the .mli define a module type. This would make easier providing a signature to an extended module. Jacques |
|
(0006839) doligez (manager) 2012-01-30 15:09 |
This is the "module type of" feature that was introduced in 3.12.0. |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2005-11-18 10:13 | administrator | New Issue | |
| 2012-01-30 15:09 | doligez | Note Added: 0006839 | |
| 2012-01-30 15:09 | doligez | Status | acknowledged => closed |
| 2012-01-30 15:09 | doligez | Resolution | open => fixed |
| 2012-01-30 15:09 | doligez | Fixed in Version | => 3.12.0 |
| 2012-01-30 15:09 | doligez | Description Updated | View Revisions |
| Copyright © 2000 - 2011 MantisBT Group |