package goblint-cil

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

An Interpreter for constructing CIL constructs

val cExp : string -> (string * Cil.formatArg) list -> Cil.exp

Constructs an expression based on the program and the list of arguments. * Each argument consists of a name followed by the actual data. This * argument will be placed instead of occurrences of "%v:name" in the pattern * (where the "v" is dependent on the type of the data). The parsing of the * string is memoized. * Only the first expression is parsed.

val cLval : string -> (string * Cil.formatArg) list -> Cil.lval

Constructs an lval based on the program and the list of arguments. * Only the first lvalue is parsed. * The parsing of the string is memoized.

val cType : string -> (string * Cil.formatArg) list -> Cil.typ

Constructs a type based on the program and the list of arguments. * Only the first type is parsed. * The parsing of the string is memoized.

val cInstr : string -> Cil.location -> (string * Cil.formatArg) list -> Cil.instr

Constructs an instruction based on the program and the list of arguments. * Only the first instruction is parsed. * The parsing of the string is memoized.

val cStmt : string -> (string -> Cil.typ -> Cil.varinfo) -> Cil.location -> (string * Cil.formatArg) list -> Cil.stmt
val cStmts : string -> (string -> Cil.typ -> Cil.varinfo) -> Cil.location -> (string * Cil.formatArg) list -> Cil.stmt list

Constructs a list of statements

val dExp : string -> Cil.exp -> Cil.formatArg list option

Deconstructs an expression based on the program. Produces an optional * list of format arguments. The parsing of the string is memoized.

val dLval : string -> Cil.lval -> Cil.formatArg list option

Deconstructs an lval based on the program. Produces an optional * list of format arguments. The parsing of the string is memoized.

val dType : string -> Cil.typ -> Cil.formatArg list option

Deconstructs a type based on the program. Produces an optional list of * format arguments. The parsing of the string is memoized.

val dInstr : string -> Cil.instr -> Cil.formatArg list option

Deconstructs an instruction based on the program. Produces an optional * list of format arguments. The parsing of the string is memoized.

val noMemoize : bool ref

If set then will not memoize the parsed patterns

val test : unit -> unit

Just a testing function

OCaml

Innovation. Community. Security.