Module Type
Types of terms
A type has to be hash-consed to be used in hash-consed terms.
- author
- Christoph Sticksel, Arjun Viswanathan
Types and hash-consing
Hashtables, maps and sets
val hash_type : t -> int
Hashing function on types
module TypeHashtbl : Stdlib.Hashtbl.S with type TypeHashtbl.key = t
Hash table over types
Constructor
val mk_bool : unit -> t
Return the boolean type
val mk_int : unit -> t
Return the integer type
val mk_real : unit -> t
Return the real decimal type
val mk_ubv : int -> t
Return the unsigned bitvector type
val mk_bv : int -> t
Return the bitvector type
val mk_abstr : string -> t
Return an abstract type
val mk_enum : string option -> string list -> t
Return an enumerated datatype type
val t_bool : t
The boolean type
val t_int : t
The integer type
val t_real : t
The real decimal type
val t_ubv : int -> t
The unsigned bitvector type
val t_bv : int -> t
The bitvector type
Type checking
Predicates
val is_bool : t -> bool
Return
true
if the type is the Boolean type
val is_int : t -> bool
Return
true
if the type is the integer type
val is_ubitvector : t -> bool
Return
true
if the type is an unsigned bitvector (integern) type
val is_bitvector : t -> bool
Return
true
if the type is a bitvector (integern) type
val bitvectorsize : t -> int
Return
true
if the type is a bitvector (integern) type
val is_uint8 : t -> bool
Return
true
if the type is the unsigned integer8 type
val is_uint16 : t -> bool
Return
true
if the type is the unsigned integer16 type
val is_uint32 : t -> bool
Return
true
if the type is the unsigned integer32 type
val is_uint64 : t -> bool
Return
true
if the type is the unsigned integer64 type
val is_int8 : t -> bool
Return
true
if the type is the integer8 type
val is_int16 : t -> bool
Return
true
if the type is the integer16 type
val is_int32 : t -> bool
Return
true
if the type is the integer32 type
val is_int64 : t -> bool
Return
true
if the type is the integer64 type
val is_int_range : t -> bool
Return
true
if the type is an integer range type
val is_enum : t -> bool
Return
true
if the type is an integer range type
val is_real : t -> bool
Return
true
if the type is the real type
val is_array : t -> bool
Return
true
if the type is an array type
val is_abstr : t -> bool
Return
true
if the type is abstract
Ranges
Arrays
Enumerated datatypes
val constructors_of_enum : t -> string list
Return constructors of an enumerated datatype
val name_of_enum : t -> string option
Return the name of an enumerated datatype encoded as int ranges
val get_constr_of_num : Numeral.t -> string
Return the constructor encoded by the numeral argument
val get_all_abstr_types : unit -> t list
Return abstract types that have been built
val get_num_of_constr : string -> Numeral.t
Return the numeral encoding of a construcor of an enumerated datatype
val enum_of_constr : string -> t
Return the enumerated dataype to which the constructor belongs
Pretty-printing
val pp_print_type_node : Stdlib.Format.formatter -> kindtype -> unit
Pretty-print a type
val pp_print_type : Stdlib.Format.formatter -> t -> unit
Pretty-print a type
val print_type : t -> unit
Pretty-print a type to the standard formatter
val string_of_type : t -> string
Return a string representation of a type
Pretty-printing for debugging - differentiates UBV and BV
val pp_print_type_node_debug : Stdlib.Format.formatter -> kindtype -> unit
Pretty-print a type
val pp_print_type_debug : Stdlib.Format.formatter -> t -> unit
Pretty-print a type
val print_type_debug : t -> unit
Pretty-print a type to the standard formatter
val string_of_type_debug : t -> string
Return a string representation of a type