Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006513OCamlOCaml typingpublic2014-08-12 10:252014-08-21 10:01
Reporterdario 
Assigned Togarrigue 
PriorityhighSeveritymajorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version4.02.0+beta1 / +rc1 
Target Version4.02.1+devFixed in Version4.02.0+dev 
Summary0006513: Fatal error: exception Ctype.Unify(_)
DescriptionThe following mli code causes the compiler to abort with a Ctype.Unify(_)
exception. This happens both in 4.01.0 and the latest 4.02 trunk snapshot
(both installed via OPAM).

To attempt compilation you need the latest Tyxml installed. Running
"ocamlfind ocamlc -package tyxml -c test.mli" suffices to reproduce
the error. (My apologies for not being able to produce a self-contained
example. I found that even small tweaks to the functor make the problem
go away.)


module type S =
sig
        type t
        type u
end


module Make: functor (Html5: Html5_sigs.T with type 'a Xml.wrap = 'a and type 'a wrap = 'a and type 'a list_wrap = 'a list) -> S with
        type t = Html5_types.div Html5.elt and
        type u = < foo: Html5.uri >
Steps To Reproduce1) Install Tyxml 3.2.x (e.g. "opam install tyxml")

2) Save code fragment as test.mli

3) ocamlfind ocamlc -package tyxml -c test.mli
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0012026)
shinwell (developer)
2014-08-20 09:47

Jacques, do you have any time to have a look at this one?
(0012032)
garrigue (manager)
2014-08-21 02:28

I'm back from holidays today and I'll try to look into it,
but the opam dependency makes things harder.
(0012037)
garrigue (manager)
2014-08-21 10:01

Fixed in 4.02, at revision 15119.

The problem was a missing Ctype.init_def(Ident.current_time())
after introducing the functor argument in the environment.
As a result, update_level would fail attempting to lower the
level of the argument below its stamp.

The following stripped down example has no dependencies:

module type S = sig type u end

module type T = sig
  type 'a wrap
  type uri
end

module Make: functor (Html5 : T with type 'a wrap = 'a) ->
  S with type u = < foo : Html5.uri >

- Issue History
Date Modified Username Field Change
2014-08-12 10:25 dario New Issue
2014-08-18 15:10 doligez Severity crash => major
2014-08-18 15:11 doligez Status new => acknowledged
2014-08-18 15:11 doligez Target Version => 4.02.0+dev
2014-08-20 09:47 shinwell Note Added: 0012026
2014-08-20 09:47 shinwell Assigned To => garrigue
2014-08-20 09:47 shinwell Status acknowledged => assigned
2014-08-20 09:50 shinwell Priority normal => high
2014-08-20 14:35 doligez Target Version 4.02.0+dev => 4.02.1+dev
2014-08-21 02:28 garrigue Note Added: 0012032
2014-08-21 10:01 garrigue Note Added: 0012037
2014-08-21 10:01 garrigue Status assigned => resolved
2014-08-21 10:01 garrigue Fixed in Version => 4.02.0+dev
2014-08-21 10:01 garrigue Resolution open => fixed


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker