package frama-c
Install
dune-project
Dependency
Authors
-
MMichele Alberti
-
TThibaud Antignac
-
GGergö Barany
-
PPatrick Baudin
-
NNicolas Bellec
-
TThibaut Benjamin
-
AAllan Blanchard
-
LLionel Blatter
-
FFrançois Bobot
-
RRichard Bonichon
-
VVincent Botbol
-
QQuentin Bouillaguet
-
DDavid Bühler
-
ZZakaria Chihani
-
LLoïc Correnson
-
JJulien Crétin
-
PPascal Cuoq
-
ZZaynah Dargaye
-
BBasile Desloges
-
JJean-Christophe Filliâtre
-
PPhilippe Herrmann
-
MMaxime Jacquemin
-
FFlorent Kirchner
-
AAlexander Kogtenkov
-
RRemi Lazarini
-
TTristan Le Gall
-
KKilyan Le Gallic
-
JJean-Christophe Léchenet
-
MMatthieu Lemerre
-
DDara Ly
-
DDavid Maison
-
CClaude Marché
-
AAndré Maroneze
-
TThibault Martin
-
FFonenantsoa Maurica
-
MMelody Méaulle
-
BBenjamin Monate
-
YYannick Moy
-
PPierre Nigron
-
AAnne Pacalet
-
VValentin Perrelle
-
GGuillaume Petiot
-
DDario Pinto
-
VVirgile Prevosto
-
AArmand Puccetti
-
FFélix Ridoux
-
VVirgile Robles
-
JJan Rochel
-
MMuriel Roger
-
CCécile Ruet-Cros
-
JJulien Signoles
-
NNicolas Stouls
-
KKostyantyn Vorobyov
-
BBoris Yakobowski
Maintainers
Sources
sha256=93a291a8764644df2f3618d7ea18258b5fbe0912ec98dfdfd180967afdf24474
doc/frama-c.kernel/Frama_c_kernel/Logic_typing/index.html
Module Frama_c_kernel.Logic_typing
Logic typing and logic environment.
val type_rel : Logic_ptree.relation -> Cil_types.relationRelation operators conversion
val type_binop : Logic_ptree.binop -> Cil_types.binopArithmetic binop conversion. Addition and Subtraction are always considered as being used on integers. It is the responsibility of the user to introduce PlusPI, MinusPI and MinusPP where needed.
val is_arithmetic_type : Cil_types.logic_type -> boolval is_integral_type : Cil_types.logic_type -> boolval is_set_type : Cil_types.logic_type -> boolval is_array_type : Cil_types.logic_type -> boolval is_pointer_type : Cil_types.logic_type -> boolval is_list_type : Cil_types.logic_type -> boolval type_of_list_elem : Cil_types.logic_type -> Cil_types.logic_typeval type_of_pointed : Cil_types.logic_type -> Cil_types.logic_typeval type_of_array_elem : Cil_types.logic_type -> Cil_types.logic_typeval type_of_set_elem : Cil_types.logic_type -> Cil_types.logic_typeval ctype_of_pointed : Cil_types.logic_type -> Cil_types.typval ctype_of_array_elem : Cil_types.logic_type -> Cil_types.typval arithmetic_conversion :
Cil_types.logic_type ->
Cil_types.logic_type ->
Cil_types.logic_typemodule Lenv : sig ... endLocal logic environment
module Type_namespace : Datatype.S with type t = type_namespacetype typing_context = {is_loop : unit -> bool;anonCompFieldName : string;conditionalConversion : Cil_types.typ -> Cil_types.typ -> Cil_types.typ;find_macro : string -> Logic_ptree.lexpr;find_var : ?label:string -> string -> Cil_types.logic_var;(*the label argument is a C label (obeying the restrictions of which label can be present in a \at). If present, the scope for searching local C variables is the one of the statement with the corresponding label.
*)find_enum_tag : string -> Cil_types.exp * Cil_types.typ;find_comp_field : Cil_types.compinfo -> string -> Cil_types.offset;find_type : type_namespace -> string -> Cil_types.typ;find_label : string -> Cil_types.stmt ref;pre_state : Lenv.t;post_state : Cil_types.termination_kind list -> Lenv.t;assigns_env : Lenv.t;silent : bool;logic_type : typing_context -> Cil_types.location -> Lenv.t -> Logic_ptree.logic_type -> Cil_types.logic_type;type_predicate : typing_context -> Lenv.t -> Logic_ptree.lexpr -> Cil_types.predicate;(*typechecks a predicate. Note that the first argument is itself a
*)typing_context, which allows for open recursion. Namely, it is possible for the extension to change the type-checking functions for the sub-nodes of the parsed tree, and not only for the toplevellexpr.type_term : typing_context -> Lenv.t -> Logic_ptree.lexpr -> Cil_types.term;type_assigns : typing_context -> accept_formal:bool -> Lenv.t -> Logic_ptree.assigns -> Cil_types.assigns;error : 'a 'b. Cil_types.location -> ('a, Format.formatter, unit, 'b) format4 -> 'a;on_error : 'a 'b. ('a -> 'b) -> ((Cil_types.location * string) -> unit) -> 'a -> 'b;(*
*)on_error f rollback xwill attempt to evaluatef x. If this triggers an error while in-kernel-warn-key annot-errormode,rollback (loc,cause)will be executed (wherelocis the location of the error andcausea text message indicating the issue) and the exception will be re-raised.
}Functions that can be called when type-checking an extension of ACSL.
remove_logic_function : string -> unit;
remove_logic_info: logic_info -> unit;
remove_logic_type: string -> unit;
remove_logic_ctor: string -> unit;
add_logic_function: logic_info -> unit;
add_logic_type: string -> logic_type_info -> unit;
add_logic_ctor: string -> logic_ctor_info -> unit;
find_all_logic_functions: string -> logic_info list;
find_logic_type: string -> logic_type_info;
find_logic_ctor: string -> logic_ctor_info;You shall now use directly functions from Logic_env and Logic_utils.
type module_builder = {add_logic_type : Cil_types.location -> Cil_types.logic_type_info -> unit;add_logic_function : Cil_types.location -> Cil_types.logic_info -> unit;
}Functions that can be called when importing external modules into ACSL. See Acsl_extension.register_module_importer for details.
module type S = sig ... endval builtin_label : string -> Cil_types.logic_builtin_label optionreturns the builtin label corresponding to the given name if it exists
val add_var : string -> Cil_types.logic_var -> Lenv.t -> Lenv.tadds a given variable in local environment.
val add_result : Lenv.t -> Cil_types.logic_type -> Lenv.tadd \result in the environment.
val enter_post_state : Lenv.t -> Cil_types.termination_kind -> Lenv.tenter a given post-state.
val post_state_env :
Cil_types.termination_kind ->
Cil_types.logic_type ->
Lenv.tenter a given post-state and put \result in the env. NB: if the kind of the post-state is neither Normal nor Returns, this is not a normal ACSL environment. Use with caution.
Internal use
val set_extension_handler :
is_extension:(plugin:string -> string -> bool) ->
typer:
(plugin:string ->
string ->
typing_context ->
Cil_types.location ->
Logic_ptree.lexpr list ->
bool * Cil_types.acsl_extension_kind) ->
typer_block:
(plugin:string ->
string ->
typing_context ->
Cil_types.location ->
(string * Logic_ptree.extended_decl list) ->
bool * Cil_types.acsl_extension_kind) ->
importer:
(plugin:string ->
string ->
module_builder ->
Cil_types.location ->
string list ->
unit) ->
unitval get_typer :
plugin:string ->
string ->
typing_context:typing_context ->
loc:Cil_types.location ->
Logic_ptree.lexpr list ->
bool * Cil_types.acsl_extension_kindType the given extension.
val get_typer_block :
plugin:string ->
string ->
typing_context:typing_context ->
loc:Logic_ptree.location ->
(string * Logic_ptree.extended_decl list) ->
bool * Cil_types.acsl_extension_kindType the given extension block.
val get_importer :
plugin:string ->
string ->
builder:module_builder ->
loc:Logic_ptree.location ->
string list ->
unitLoad the given module importer extension.