Frama-C:
Plug-ins:
Libraries:

Frama-C API - Hptset

Set of kernel functions.

include Datatype.S_with_collections with type t = unit map
include Datatype.S with type t = unit map
include Datatype.S_no_copy with type t = unit map
val name : string

Unique name of the datatype.

val descr : t Descr.t

Datatype descriptor.

val packed_descr : Structural_descr.pack

Packed version of the descriptor.

val reprs : t list

List of representants of the descriptor.

val hash : t -> int

Hash function: same spec than Hashtbl.hash.

val pretty : Stdlib.Format.formatter -> t -> unit

Pretty print each value in an user-friendly way.

val mem_project : (Project_skeleton.t -> bool) -> t -> bool

mem_project f x must return true iff there is a value p of type Project.t in x such that f p returns true.

val copy : t -> t

Deep copy: no possible sharing between x and copy x.

module Set : Datatype.Set with type elt = t
module Map : Datatype.Map with type key = t
module Hashtbl : Datatype.Hashtbl with type key = t

The datatype of sets.

include Hptset.S_Basic_Compare with type t := t with type elt = Cil_types.kernel_function
val empty : t
val is_empty : t -> bool
val mem : elt -> t -> bool
val add : elt -> t -> t
val singleton : elt -> t
val remove : elt -> t -> t
val union : t -> t -> t
val inter : t -> t -> t
val diff : t -> t -> t
val compare : t -> t -> int
val equal : t -> t -> bool
val subset : t -> t -> bool
val iter : (elt -> unit) -> t -> unit
val fold : (elt -> 'a -> 'a) -> t -> 'a -> 'a
val for_all : (elt -> bool) -> t -> bool
val exists : (elt -> bool) -> t -> bool
val filter : (elt -> bool) -> t -> t
val partition : (elt -> bool) -> t -> t * t
val cardinal : t -> int
val elements : t -> elt list
val choose : t -> elt
val find : elt -> t -> elt
val of_list : elt list -> t
val contains_single_elt : t -> elt option
val intersects : t -> t -> bool

intersects s1 s2 returns true if and only if s1 and s2 have an element in common

type action =
  1. | Neutral
  2. | Absorbing
  3. | Traversing of elt -> bool
val merge : cache:Hptmap_sig.cache_type -> symmetric:bool -> idempotent:bool -> decide_both:(elt -> bool) -> decide_left:action -> decide_right:action -> t -> t -> t
val from_map : 'a map -> t
val fold2_join_heterogeneous : cache:Hptmap_sig.cache_type -> empty_left:('a map -> 'b) -> empty_right:(t -> 'b) -> both:(elt -> 'a -> 'b) -> join:('b -> 'b -> 'b) -> empty:'b -> t -> 'a map -> 'b
val replace : elt map -> t -> bool * t

replace shape set replaces the elements of set according to shape. The returned boolean indicates whether the set has been modified; it is false when the intersection between shape and set is empty.

val clear_caches : unit -> unit

Clear all the caches used internally by the functions of this module. Those caches are not project-aware, so this function must be called at least each a project switch occurs.

val pretty_debug : t Pretty_utils.formatter