Sstt.TagIdentifiers used for tagged type.
Identifiers used for tagged type.
val mk : string -> tmk name makes a new identifier of name name. This will generate a fresh identifier even if another identifier has name name.
val name : t -> stringname t returns the name of the identifier t.
val hash : t -> intval pp : Stdlib.Format.formatter -> t -> unitpp fmt t prints the name of t using the formatter fmt.
val pp_unique : Stdlib.Format.formatter -> t -> unitpp_unique fmt t prints the name of t followed by a unique integer to disambiguate it from other identifiers with the same name.
The properties of the interpretation of a tag. A tagged type \texttt{tag}(s) denotes the image of s by a function f_\texttt{tag} that is specific to the tag; these properties describe that function, and are what makes it possible to compare two types tagged with the same tag.
NoProperty: nothing is known about f_\texttt{tag}, so \texttt{tag}(s) and \texttt{tag}(s') can only be related when s and s' are equivalent.Monotonic: f_\texttt{tag} is monotonic, that is, s <= s' implies \texttt{tag}(s) \leq \texttt{tag}(s'). In addition, preserves_cup (resp. preserves_cap) states that it distributes over unions (resp. intersections), that is, \texttt{tag}(s\cup s') \equiv \texttt{tag}(s)\cup\texttt{tag}(s') (resp. with \cap), and preserves_extremum states that it preserves the corresponding extremum, that is, \texttt{tag}( 𝟘) is empty (if preserves_cap is true) and \texttt{tag}( 𝟙) contains every value tagged with this tag (if preserves_cup is true).mk' name prop makes a new tag of name name whose interpretation satisfies prop. As mk, it generates a fresh tag even if another tag has the same name.