package frama-c

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Sets of intervals with a lattice structure. Consecutive intervals are automatically fused.

include Int_Intervals_sig.S with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
include Lattice_type.Full_Lattice with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
include Lattice_type.Bounded_Join_Semi_Lattice with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
include Lattice_type.Join_Semi_Lattice with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t

datatype of element of the lattice

include Datatype.S with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
include Datatype.S_no_copy with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
include Datatype.Ty with type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
type t = Frama_c_kernel.Offsetmap.Int_Intervals.t
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 equal : t -> t -> bool

Equality: same spec than Stdlib.(=).

val compare : t -> t -> int

Comparison: same spec than Stdlib.compare.

val hash : t -> int

Hash function: same spec than Hashtbl.hash.

val pretty : 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.

val join : t -> t -> t

over-approximation of union

val is_included : t -> t -> bool

is first argument included in the second?

val bottom : t

smallest element

include Lattice_type.With_Top with type t := t
val top : t

largest element

include Lattice_type.With_Narrow with type t := t
val narrow : t -> t -> t

over-approximation of intersection

include Lattice_type.With_Under_Approximation with type t := t

under-approximation of union

val meet : t -> t -> t

under-approximation of intersection

include Lattice_type.With_Intersects with type t := t
val intersects : t -> t -> bool

intersects t1 t2 returns true iff the intersection of t1 and t2 is non-empty.

include Lattice_type.With_Diff with type t := t
val diff : t -> t -> t

diff t1 t2 is an over-approximation of t1-t2. t2 must be an under-approximation or exact.

val is_top : t -> bool
val inject_itv : Int_Intervals_sig.itv -> t
val inject : Int_Intervals_sig.itv list -> t
val from_ival_size : Ival.t -> Int_Base.t -> t

Conversion from an ival, which represents the beginning of each interval. The size if taken from the Int_Base.t argument. If the result contains more than -plevel arguments, it is automatically over-approximated.

val from_ival_size_under : Ival.t -> Int_Base.t -> t

Same as from_ival_size, except that the result is an under-approximation if the ival points to too many locations

val project_set : t -> Int_Intervals_sig.itv list

May raise Error_Top. As intervals are not represented as lists, this function has an overhead. Use iterators whenever possible instead.

val project_singleton : t -> Int_Intervals_sig.itv option

Iterators

val fold : (Int_Intervals_sig.itv -> 'a -> 'a) -> t -> 'a -> 'a

May raise Error_Top

val iter : (Int_Intervals_sig.itv -> unit) -> t -> unit

May raise Error_Top

val pretty_typ : Cil_types.typ option -> t Pretty_utils.formatter

Pretty-printer that supposes the intervals are subranges of a C type, and use the type to print nice offsets

val range_covers_whole_type : Cil_types.typ -> t -> bool

Does the interval cover the entire range of bits that are valid for the given type.

OCaml

Innovation. Community. Security.