[clean-list] instantiation of attributed type variables
Wolfgang Jeltsch
wolfgang at jeltsch.net
Mon Aug 22 16:31:58 MEST 2005
Hello again,
how are type variables instantiated in the uniqueness typing system described
in "Uniqueness Typing for Functional Programming with Graph Rewriting
Semantics"? Is a type variable replaced by a type without a top-level
attribute (since the variable provides the attribute) or is the variable
together with the attribute replaced by a uniqueness type which has the same
attribute.
Take, for example, the type a^* -> a^x where ^* means "unique" and ^x means
"non-unique". If the first of the above variants is true, this type can be
specialized to Integer^* -> Integer^x by replacing a with Integer. If the
second variant is true, no specialization is possible, since each occurence
of the type variable a together with an uniqueness attribute has to be
replaced with the same attributed type but this type has to have ^* as well
as ^x as its uniqueness attribute because the type variable a appears with
both attributes in the above function type.
Best regards,
Wolfgang
More information about the clean-list
mailing list