Got it. I missed that somehow until now. Indeed using eta expansion to enforce introducing variable-like constructors works well, and looks like a very reasonable work around for the cases I have in mind. Thank you very much for the relevant links and the quick answers. 2013/7/26 Alain Frisch > On 7/26/2013 10:27 PM, Gabriel Scherer wrote: > >> This is explained in the manual (emphasis mine) >> http://caml.inria.fr/pub/docs/**manual-ocaml/manual021.html#**toc85 >> >> The constraints associated to each constructor can be recovered through >>> pattern-matching. >>> Namely, **if the type of the scrutinee of a pattern-matching contains a >>> locally abstract type**, >>> this type can be refined according to the constructor used. >>> >> >> The only types that can be refined by the type equalities introduced >> by GADT are locally abstract types, the variable-like constructor "a" >> introduced by the "(type a)" and "foo : type a . bar" syntaxes. Your >> first two examples have no locally abstract type, only type members of >> modules, so there was no GADT refinement happening. >> > > A feature request related to allowing more kinds of types to be refined by > GADT patterns (abstract types in the current environment, introduced by > unpacking a module -- but the same would be useful for abstract types in a > functor's argument): > > http://caml.inria.fr/mantis/**view.php?id=5713 > > -- Alain >