blob: cafe04f4404382d42e702a3c28ec5cf76a83a93f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
(* TEST
* expect
*)
class type ['e] t = object('s)
method update : 'e -> 's
end;;
[%%expect{|
class type ['e] t = object ('a) method update : 'e -> 'a end
|}];;
module type S = sig
class base : 'e -> ['e] t
end;;
[%%expect{|
Line 2, characters 2-27:
2 | class base : 'e -> ['e] t
^^^^^^^^^^^^^^^^^^^^^^^^^
Error: Some type variables are unbound in this type:
class base : 'e -> ['e] t
The method update has type 'e -> #base where 'e is unbound
|}];;
|