Frama-C:
Plug-ins:
Libraries:

Frama-C API - Function

Instance of Polymorphic2 for functions: same signature than Polymorphic2 with possibility to specify a label for the function parameter.

type ('a, 'b) poly = 'a -> 'b
val instantiate : ?label:(string * (unit -> 'a) option) -> 'a t -> 'b t -> ('a -> 'b) t * bool

Possibility to add a label for the parameter.

  • ~label:(p,None) for a mandatory labeled parameter p;
  • ~label:(p,Some f) for an optional labeled parameter p, with default value f ().
val is_instance_of : 'a t -> bool
val get_instance : ('a -> 'b) t -> 'a t * 'b t * string option
val get_optional_argument : ('a -> 'b) t -> (unit -> 'a) option