34 std::set<std::string> s;
59 const std::string &path,
68 if(
ext!=
nullptr && std::string(
ext)==
".ipp")
70 std::ifstream
infile(path);
85 const std::string &path)
123 const std::string &
module)
155 if(
item.is_linkage_spec())
158 item.get_linkage_spec();
162 for(
const auto &i : linkage_spec.
items())
167 else if(
item.is_namespace_spec())
170 item.get_namespace_spec();
180 else if(
item.is_using())
187 out <<
cpp_using.name().pretty() <<
'\n';
190 else if(
item.is_declaration())
195 out <<
"UNKNOWN: " <<
item.pretty() <<
'\n';
231 const std::string &code,
bool ansi_c_entry_point(symbol_table_baset &symbol_table, message_handlert &message_handler, const c_object_factory_parameterst &object_factory_parameters)
bool c_preprocess(std::istream &instream, std::ostream &outstream, message_handlert &message_handler)
ANSI-C preprocessing.
virtual void output(const namespacet &ns, const irep_idt &function_id, const goto_programt &goto_program, std::ostream &out) const
Output the abstract states for a single function.
ait supplies three of the four components needed: an abstract interpreter (in this case handling func...
struct configt::ansi_ct ansi_c
bool from_type(const typet &type, std::string &code, const namespacet &ns) override
Formats the given type in a language-specific way.
bool typecheck(symbol_table_baset &symbol_table, const std::string &module) override
bool type_to_name(const typet &type, std::string &name, const namespacet &ns) override
Encodes the given type in a language-specific way.
c_object_factory_parameterst object_factory_params
bool to_expr(const std::string &code, const std::string &module, exprt &expr, const namespacet &ns) override
Parses the given string into an expression.
std::set< std::string > extensions() const override
~cpp_languaget() override
bool generate_support_functions(symbol_table_baset &symbol_table) override
Create language-specific support functions, such as __CPROVER_start, __CPROVER_initialize and languag...
bool from_expr(const exprt &expr, std::string &code, const namespacet &ns) override
Formats the given expression in a language-specific way.
bool preprocess(std::istream &instream, const std::string &path, std::ostream &outstream) override
ANSI-C preprocessing.
bool parse(std::istream &instream, const std::string &path) override
void modules_provided(std::set< std::string > &modules) override
cpp_parse_treet cpp_parse_tree
void show_parse(std::ostream &out) override
const itemst & items() const
void swap(cpp_parse_treet &cpp_parse_tree)
virtual void clear() override
cpp_parse_treet parse_tree
virtual bool parse() override
ansi_c_parsert::modet mode
Base class for all expressions.
const irep_idt & get(const irep_idt &name) const
message_handlert & get_message_handler()
virtual void set_message_handler(message_handlert &_message_handler)
mstreamt & result() const
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
void set_file(const irep_idt &file)
The symbol table base class interface.
The type of an expression, extends irept.
void cpp_internal_additions(std::ostream &out)
std::unique_ptr< languaget > new_cpp_language()
std::string cpp_type2name(const typet &type)
bool cpp_typecheck(cpp_parse_treet &cpp_parse_tree, symbol_table_baset &symbol_table, const std::string &module, message_handlert &message_handler)
C++ Language Type Checking.
std::string type2cpp(const typet &type, const namespacet &ns)
std::string expr2cpp(const exprt &expr, const namespacet &ns)
std::string get_base_name(const std::string &in, bool strip_suffix)
cleans a filename from path and extension
bool linking(symbol_table_baset &dest_symbol_table, const symbol_table_baset &new_symbol_table, message_handlert &message_handler)
Merges the symbol table new_symbol_table into dest_symbol_table, renaming symbols from new_symbol_tab...
void remove_internal_symbols(symbol_table_baset &symbol_table, message_handlert &mh, const bool keep_file_local)
Removes internal symbols from a symbol table A symbol is EXPORTED if it is a.
Remove symbols that are internal only.