2828 ============================================================================= *)
2929
3030(* chlib *)
31- open CHLanguage
3231open CHNumerical
3332open CHPretty
3433
@@ -48,45 +47,45 @@ open CCHBasicTypes
4847 *)
4948
5049type machine_sizes_t = {
51- sizeof_short : xpr_t ;
52- sizeof_int : xpr_t ;
53-
54- sizeof_bool : xpr_t ;
55- sizeof_long : xpr_t ;
56-
57- sizeof_longlong : xpr_t ;
58- sizeof_ptr : xpr_t ;
59- sizeof_enum : xpr_t ;
60- sizeof_float : xpr_t ;
61- sizeof_double : xpr_t ;
62-
63- sizeof_longdouble : xpr_t ;
64- sizeof_void : xpr_t ;
65- sizeof_fun : xpr_t ;
66-
67- alignof_short : xpr_t ;
68- alignof_int : xpr_t ;
69- alignof_bool : xpr_t ;
70- alignof_long : xpr_t ;
71-
72- alignof_longlong : xpr_t ;
73- alignof_ptr : xpr_t ;
74- alignof_enum : xpr_t ;
75- alignof_float : xpr_t ;
76-
77- alignof_double : xpr_t ;
78- alignof_longdouble : xpr_t ;
79- alignof_str : xpr_t ;
80- alignof_fun : xpr_t ;
81- alignof_aligned : xpr_t ;
50+ sizeof_short : xpr_t ;
51+ sizeof_int : xpr_t ;
52+
53+ sizeof_bool : xpr_t ;
54+ sizeof_long : xpr_t ;
55+
56+ sizeof_longlong : xpr_t ;
57+ sizeof_ptr : xpr_t ;
58+ sizeof_enum : xpr_t ;
59+ sizeof_float : xpr_t ;
60+ sizeof_double : xpr_t ;
61+
62+ sizeof_longdouble : xpr_t ;
63+ sizeof_void : xpr_t ;
64+ sizeof_fun : xpr_t ;
65+
66+ alignof_short : xpr_t ;
67+ alignof_int : xpr_t ;
68+ alignof_bool : xpr_t ;
69+ alignof_long : xpr_t ;
70+
71+ alignof_longlong : xpr_t ;
72+ alignof_ptr : xpr_t ;
73+ alignof_enum : xpr_t ;
74+ alignof_float : xpr_t ;
75+
76+ alignof_double : xpr_t ;
77+ alignof_longdouble : xpr_t ;
78+ alignof_str : xpr_t ;
79+ alignof_fun : xpr_t ;
80+ alignof_aligned : xpr_t ;
8281}
8382
8483type max_sizes_t = {
85- sizeof_int : int ;
86- sizeof_float : int ;
87- sizeof_void : int ;
88- sizeof_ptr : int ;
89- sizeof_fun : int ;
84+ sizeof_int : int ;
85+ sizeof_float : int ;
86+ sizeof_void : int ;
87+ sizeof_ptr : int ;
88+ sizeof_fun : int ;
9089 sizeof_enum : int
9190 }
9291
@@ -510,18 +509,18 @@ type annotated_xpredicate_t = (xpredicate_t * summary_annotation_t)
510509
511510(* data structure condition *)
512511type ds_condition_t = {
513- dsc_name : string ;
514- dsc_ckey : int ;
512+ dsc_name : string ;
513+ dsc_ckey : int ;
515514 dsc_fields : xpredicate_t list
516515 }
517516
518517type function_summary_t = {
519- fs_fname : string ;
518+ fs_fname : string ;
520519 fs_domainref : (string * string ) option ; (* specialized reasoning domain *)
521- fs_params : (string * int ) list ;
522- fs_preconditions : annotated_xpredicate_t list ;
523- fs_postconditions : annotated_xpredicate_t list ;
524- fs_error_postconditions : annotated_xpredicate_t list ;
520+ fs_params : (string * int ) list ;
521+ fs_preconditions : annotated_xpredicate_t list ;
522+ fs_postconditions : annotated_xpredicate_t list ;
523+ fs_error_postconditions : annotated_xpredicate_t list ;
525524 fs_sideeffects : annotated_xpredicate_t list
526525 }
527526
@@ -601,8 +600,8 @@ type contract_instr_t =
601600 SetVar of int * s_term_t * s_term_t (* line, lhs, rhs *)
602601
603602type contract_note_t = {
604- cn_tag : string ;
605- cn_prq : string ;
603+ cn_tag : string ;
604+ cn_prq : string ;
606605 cn_txt : string
607606 }
608607
@@ -630,13 +629,13 @@ class type function_contract_int =
630629 end
631630
632631type contract_global_var_t = {
633- cgv_name : string ;
634- cgv_value : int option ;
635- cgv_lb : int option ;
636- cgv_ub : int option ;
637- cgv_static : bool ;
638- cgv_const : bool ;
639- cgv_notnull : bool ;
632+ cgv_name : string ;
633+ cgv_value : int option ;
634+ cgv_lb : int option ;
635+ cgv_ub : int option ;
636+ cgv_static : bool ;
637+ cgv_const : bool ;
638+ cgv_notnull : bool ;
640639 cgv_initialized_fields : string list
641640 }
642641
@@ -671,11 +670,16 @@ class type global_contract_int =
671670
672671
673672type analysis_level_t =
674- | UndefinedBehavior (* only indicate undefined behavior (Red) *)
675- | ImplementationDefinedBehavior (* indicate undefined behavior and implementation
676- defined behavior (Red,Purple) (default) *)
677- | ValueWrapAround (* indicate undefined behavior, implementation-defined behavior,
678- and value wrap around of unsigned integers (Red, Purple, Blue) *)
673+ | UndefinedBehavior
674+ (* * only indicate undefined behavior (Red) *)
675+
676+ | ImplementationDefinedBehavior
677+ (* * indicate undefined behavior and implementation defined behavior
678+ (Red,Purple) (default) *)
679+
680+ | ValueWrapAround
681+ (* * indicate undefined behavior, implementation-defined behavior, and value
682+ wrap around of unsigned integers (Red, Purple, Blue) *)
679683
680684
681685(* * Paths and analysis options*)
0 commit comments