12 #ifndef CPROVER_CPP_CPP_LANGUAGE_H
13 #define CPROVER_CPP_CPP_LANGUAGE_H
33 std::istream &instream,
34 const std::string &path,
35 std::ostream &outstream,
39 std::istream &instream,
40 const std::string &path,
49 const std::string &module,
55 const std::string &module,
83 const std::string &code,
84 const std::string &module,
91 return std::make_unique<cpp_languaget>();
94 std::string
id()
const override {
return "cpp"; }
96 std::set<std::string>
extensions()
const override;
bool from_type(const typet &type, std::string &code, const namespacet &ns) override
Formats the given type in a language-specific way.
bool parse(std::istream &instream, const std::string &path, message_handlert &message_handler) override
void set_language_options(const optionst &options, message_handlert &) override
Set language-specific options.
bool type_to_name(const typet &type, std::string &name, const namespacet &ns) override
Encodes the given type in a language-specific way.
std::string id() const override
c_object_factory_parameterst object_factory_params
std::unique_ptr< languaget > new_language() override
bool typecheck(symbol_table_baset &symbol_table, const std::string &module, message_handlert &message_handler) override
bool preprocess(std::istream &instream, const std::string &path, std::ostream &outstream, message_handlert &message_handler) override
ANSI-C preprocessing.
std::string description() const override
bool merge_symbol_table(symbol_table_baset &dest, symbol_table_baset &src, const std::string &module, class replace_symbolt &replace_symbol) const
void show_parse(std::ostream &out, message_handlert &) override
bool generate_support_functions(symbol_table_baset &symbol_table, message_handlert &message_handler) override
Create language-specific support functions, such as __CPROVER_start, __CPROVER_initialize and languag...
std::set< std::string > extensions() const override
std::string main_symbol()
~cpp_languaget() override
bool from_expr(const exprt &expr, std::string &code, const namespacet &ns) override
Formats the given expression in a language-specific way.
void modules_provided(std::set< std::string > &modules) override
bool to_expr(const std::string &code, const std::string &module, exprt &expr, const namespacet &ns, message_handlert &message_handler) override
Parses the given string into an expression.
cpp_parse_treet cpp_parse_tree
Base class for all expressions.
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
Replace a symbol expression by a given expression.
The symbol table base class interface.
The type of an expression, extends irept.
std::unique_ptr< languaget > new_cpp_language()
Abstract interface to support a programming language.
void set(const optionst &)
Assigns the parameters from given options.