Calculator Step 4

- Main Page
- Classes
- Files

- File List
- File Members

variables.hpp
Go to the documentation of this file.
1 #ifndef VARIABLES_HPP_
2 #define VARIABLES_HPP_
3
4 #include <map>
5 #include <string>
6
7 #include "node.hpp"
8
13 typedef std::map<std::string, node> symbol_table;
14
19 class set_symbol_table
20 {
21 public:
22 set_symbol_table(symbol_table const& symtab);
23 ~set_symbol_table();
24 };
25
30 node get_variable(std::string const& name);
31
37 node get_function(std::string const& name);
38
43 void set_variable(std::string const& name, node value);
44
49 void set_function(std::string const& name, node definition);
50
51 #endif
get_function
node get_function(std::string const &name)
Definition: variables.cpp:61
node
Definition: node.hpp:26
set_symbol_table
Definition: variables.hpp:19
set_variable
void set_variable(std::string const &name, node value)
Definition: variables.cpp:56
set_function
void set_function(std::string const &name, node value)
Definition: variables.cpp:70
set_symbol_table::~set_symbol_table
~set_symbol_table()
Definition: variables.cpp:27
node.hpp
set_symbol_table::set_symbol_table
set_symbol_table(symbol_table const &symtab)
Definition: variables.cpp:22
get_variable
node get_variable(std::string const &name)
Definition: variables.cpp:45
symbol_table
std::map< std::string, node > symbol_table
Definition: variables.hpp:13