cprover
fresh_symbol.h File Reference

Fresh auxiliary symbol creation. More...

#include <string>
#include <util/irep.h>
#include <util/source_location.h>
#include <util/symbol_table.h>
#include <util/type.h>
Include dependency graph for fresh_symbol.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

symboltget_fresh_aux_symbol (const typet &type, const std::string &name_prefix, const std::string &basename_prefix, const source_locationt &source_location, const irep_idt &symbol_mode, symbol_tablet &symbol_table)
 Installs a fresh-named symbol with the requested name pattern. More...
 

Detailed Description

Fresh auxiliary symbol creation.

Definition in file fresh_symbol.h.

Function Documentation

§ get_fresh_aux_symbol()

symbolt& get_fresh_aux_symbol ( const typet type,
const std::string &  name_prefix,
const std::string &  basename_prefix,
const source_locationt source_location,
const irep_idt symbol_mode,
symbol_tablet symbol_table 
)

Installs a fresh-named symbol with the requested name pattern.

parameters: type: type of new symbol
name_prefix, basename_prefix: new symbol will be named name_prefix::basename_prefix$num unless name_prefix is empty, in which case the :: prefix is omitted. source_location: new symbol source loc symbol_mode: new symbol mode symbol_table: table to add the new symbol to

Definition at line 22 of file fresh_symbol.cpp.

References symbolt::base_name, id2string(), symbolt::location, symbolt::mode, symbol_tablet::move(), symbolt::name, and symbolt::type.

Referenced by c_new_tmp_symbol(), remove_function_pointerst::fix_return_type(), remove_instanceoft::lower_instanceof(), goto_convertt::make_compound_literal(), new_tmp_symbol(), goto_convertt::new_tmp_symbol(), and code_contractst::new_tmp_symbol().