Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0005164OCamlOCaml generalpublic2010-10-06 17:222010-10-07 04:24
Reportersebmondet 
Assigned To 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version3.12.0 
Target VersionFixed in Version3.12.1+dev 
Summary0005164: Multiple 'module type of' are incompatible
DescriptionTrying to compile this:

 module type INCLUDING = sig
   include module type of List
   include module type of ListLabels
 end

 module Including_typed: INCLUDING = struct
   include List
   include ListLabels
 end

gives the error:
 File "tt.ml", line 7, characters 36-82:
 Error: Signature mismatch:
       Modules do not match:
         sig
           val length : 'a list -> int
      (* ... the whole ListLabels signature ... *)
         end
       is not included in
         INCLUDING
       Values do not match:
         val iter : f:('a -> unit) -> 'a list -> unit
       is not included in
         val iter : ('a -> unit) -> 'a list -> unit

with:
 $ ocamlc -version
 3.12.0

(compiled from GODI)

TagsNo tags attached.
Attached Files

- Relationships
has duplicate 0004487closedgarrigue Unable to override a value in a module type with ocamlc. 

-  Notes
(0005677)
garrigue (manager)
2010-10-07 04:24

Well spotted.
There was a very stupid bug in 3.12, where only the first repeated definition
was discarded when including signatures, but other repetitions were kept.

This is fixed in revision 10706, file typemod.ml.

- Issue History
Date Modified Username Field Change
2010-10-06 17:22 sebmondet New Issue
2010-10-07 04:24 garrigue Note Added: 0005677
2010-10-07 04:24 garrigue Status new => closed
2010-10-07 04:24 garrigue Resolution open => fixed
2010-10-07 04:24 garrigue Fixed in Version => 3.12.1+dev
2010-12-13 13:05 garrigue Relationship added has duplicate 0004487


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker