package mopsa
MOPSA: A Modular and Open Platform for Static Analysis using Abstract Interpretation
Install
Dune Dependency
Authors
Maintainers
Sources
mopsa-analyzer-v1.1.tar.gz
md5=fdee20e988343751de440b4f6b67c0f4
sha512=f5cbf1328785d3f5ce40155dada2d95e5de5cce4f084ea30cfb04d1ab10cc9403a26cfb3fa55d0f9da72244482130fdb89c286a9aed0d640bba46b7c00e09500
doc/parsing/Parsing/Ast/index.html
Module Parsing.Ast
Source
Abstract syntax tree for C stubs. It is similar to the CST except:
- predicates are expanded.
- types and variables are resolved using the context of the Clang parser.
- calls to sizeof are resolved using Clang's target information.
- stubs and cases record their locals and assignments.
Source
type stub = {
stub_name : string;
stub_params : var list;
stub_locals : local Mopsa_utils.Location.with_range list;
stub_assigns : assigns Mopsa_utils.Location.with_range list;
stub_body : section list;
stub_range : Mopsa_utils.Location.range;
}
Stub sections
*****************
Source
and leaf =
| S_local of local Mopsa_utils.Location.with_range
| S_assumes of assumes Mopsa_utils.Location.with_range
| S_requires of requires Mopsa_utils.Location.with_range
| S_assigns of assigns Mopsa_utils.Location.with_range
| S_ensures of ensures Mopsa_utils.Location.with_range
| S_free of free Mopsa_utils.Location.with_range
| S_message of message Mopsa_utils.Location.with_range
Source
and case = {
case_label : string;
case_body : leaf list;
case_locals : local Mopsa_utils.Location.with_range list;
case_assigns : assigns Mopsa_utils.Location.with_range list;
case_range : Mopsa_utils.Location.range;
}
Leaf sections
**********************
Source
and local_value =
| L_new of resource
| L_call of Mopsa_c_parser.C_AST.func Mopsa_utils.Location.with_range * expr Mopsa_utils.Location.with_range list
Source
and assigns = {
assign_target : expr Mopsa_utils.Location.with_range;
assign_offset : interval list;
}
Expressions
*=*=*=*=*=*=*=*
Source
and expr_kind =
| E_top of Mopsa_c_parser.C_AST.type_qual
| E_int of Z.t
| E_float of float
| E_string of string
| E_char of int
| E_invalid
| E_var of var
| E_unop of unop * expr Mopsa_utils.Location.with_range
| E_binop of binop * expr Mopsa_utils.Location.with_range * expr Mopsa_utils.Location.with_range
| E_addr_of of expr Mopsa_utils.Location.with_range
| E_deref of expr Mopsa_utils.Location.with_range
| E_cast of Mopsa_c_parser.C_AST.type_qual * bool * expr Mopsa_utils.Location.with_range
| E_subscript of expr Mopsa_utils.Location.with_range * expr Mopsa_utils.Location.with_range
| E_member of expr Mopsa_utils.Location.with_range * int * string
| E_arrow of expr Mopsa_utils.Location.with_range * int * string
| E_conditional of expr Mopsa_utils.Location.with_range * expr Mopsa_utils.Location.with_range * expr Mopsa_utils.Location.with_range
| E_builtin_call of builtin * expr Mopsa_utils.Location.with_range list
| E_raise of string
| E_return
Source
and interval = {
itv_lb : expr Mopsa_utils.Location.with_range;
(*lower bound
*)itv_open_lb : bool;
(*open lower bound
*)itv_ub : expr Mopsa_utils.Location.with_range;
(*upper bound
*)itv_open_ub : bool;
(*open upper bound
*)
}
Formulas
************
Source
and formula =
| F_expr of expr Mopsa_utils.Location.with_range
| F_bool of bool
| F_binop of log_binop * formula Mopsa_utils.Location.with_range * formula Mopsa_utils.Location.with_range
| F_not of formula Mopsa_utils.Location.with_range
| F_forall of var * set * formula Mopsa_utils.Location.with_range
| F_exists of var * set * formula Mopsa_utils.Location.with_range
| F_in of expr Mopsa_utils.Location.with_range * set
| F_otherwise of formula Mopsa_utils.Location.with_range * expr Mopsa_utils.Location.with_range
| F_if of formula Mopsa_utils.Location.with_range * formula Mopsa_utils.Location.with_range * formula Mopsa_utils.Location.with_range
Utility functions
*********************
Pretty printers
*******************
Source
val pp_list :
(Stdlib.Format.formatter -> 'a -> unit) ->
(unit, Stdlib.Format.formatter, unit) Stdlib.format ->
Stdlib.Format.formatter ->
'a list ->
unit
Source
val pp_requires :
Stdlib.Format.formatter ->
formula Mopsa_utils.Location.with_range Mopsa_utils.Location.with_range ->
unit
Source
val pp_ensures :
Stdlib.Format.formatter ->
formula Mopsa_utils.Location.with_range Mopsa_utils.Location.with_range ->
unit
Source
val pp_free :
Stdlib.Format.formatter ->
expr Mopsa_utils.Location.with_range Mopsa_utils.Location.with_range ->
unit
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page