Merlin_sherlodoc.Type_expr
SourceA representation of internal types, with superfluous information removed to make it easier to compare them and calculate their distance.
Type variables are indexed by integers calculated according to their positions. For example, in the expression of type 'a -> 'b -> 'c
, respectively 'a
will have the value 1
, 'b
will have the value 2
and ’c
will have the value 3
.
This makes 'a -> 'b -> 'c
isomorphic to ’foo -> 'bar -> 'baz
.
normalize_type_parameters ty
replace string based type variables to integer based type variables.