#include <ss_ss2pi_base.g.hh>
Inheritance diagram for lestes::lang::cplus::sem::ss_stmt2pi:

Public Member Functions | |
| ptr< ss_function_declaration > | current_function_get () const |
| The method current_function_get returns the value of the field ss_stmt2pi::current_function. | |
| void | current_function_set (const ptr< ss_function_declaration > &) |
| The method current_function_set sets the field ss_stmt2pi::current_function to the given value. | |
| ptr< variable_map_type > | local_variable_map_get () const |
| The method local_variable_map_get returns the value of the field ss_stmt2pi::local_variable_map. | |
| void | local_variable_map_set (const ptr< variable_map_type > &) |
| The method local_variable_map_set sets the field ss_stmt2pi::local_variable_map to the given value. | |
| ptr< variable_map_type > | namespace_variable_map_get () const |
| The method namespace_variable_map_get returns the value of the field ss_stmt2pi::namespace_variable_map. | |
| void | namespace_variable_map_set (const ptr< variable_map_type > &) |
| The method namespace_variable_map_set sets the field ss_stmt2pi::namespace_variable_map to the given value. | |
| void | mem_variable_set (ptr< ss_declaration >, ptr< ::lestes::backend_v2::intercode::pi_mem_factory >) |
| API to store record of memmory placeholder for variable. It automaticaly distinguishes between global scope and local scope, where record shall be added (according to "current_function" member). | |
| ptr< ::lestes::backend_v2::intercode::pi_mem_factory > | mem_variable_get (ptr< ss_declaration >) |
| API to look-up memory placeholder, which was allocated for variable. It searches in both local and global scope. It also automaticaly inserts new record for alias and function parameter declarations. | |
| virtual void | visit_ss_compound_stmt (ptr< ::lestes::lang::cplus::sem::ss_compound_stmt >) |
| virtual void | visit_ss_decl_stmt (ptr< ::lestes::lang::cplus::sem::ss_decl_stmt >) |
| virtual void | visit_ss_try (ptr< ::lestes::lang::cplus::sem::ss_try >) |
| virtual void | visit_ss_break (ptr< ::lestes::lang::cplus::sem::ss_break >) |
| virtual void | visit_ss_return (ptr< ::lestes::lang::cplus::sem::ss_return >) |
| virtual void | visit_ss_goto (ptr< ::lestes::lang::cplus::sem::ss_goto >) |
| virtual void | visit_ss_expr_stmt (ptr< ::lestes::lang::cplus::sem::ss_expr_stmt >) |
| virtual void | visit_ss_continue (ptr< ::lestes::lang::cplus::sem::ss_continue >) |
| virtual void | visit_ss_if_stmt (ptr< ::lestes::lang::cplus::sem::ss_if_stmt >) |
| virtual void | visit_ss_catch (ptr< ::lestes::lang::cplus::sem::ss_catch >) |
| virtual void | visit_ss_switch_stmt (ptr< ::lestes::lang::cplus::sem::ss_switch_stmt >) |
| virtual void | visit_ss_do (ptr< ::lestes::lang::cplus::sem::ss_do >) |
| virtual void | visit_ss_while (ptr< ::lestes::lang::cplus::sem::ss_while >) |
| virtual void | visit_ss_for (ptr< ::lestes::lang::cplus::sem::ss_for >) |
| virtual ptr< reflection_list > | reflection_get () const |
| for purposes of dumping | |
| virtual ptr< field_list_list > | field_values_get () const |
| for purposes of dumping | |
Static Public Member Functions | |
| static ptr< ss_stmt2pi > | create (ptr< ss_function_declaration > a__ss_stmt2pi__current_function, ptr< variable_map_type > a__ss_stmt2pi__local_variable_map, ptr< variable_map_type > a__ss_stmt2pi__namespace_variable_map) |
| First generated factory method for class ss_stmt2pi. | |
Protected Member Functions | |
| ss_stmt2pi (ptr< ss_function_declaration > a__ss_stmt2pi__current_function, ptr< variable_map_type > a__ss_stmt2pi__local_variable_map, ptr< variable_map_type > a__ss_stmt2pi__namespace_variable_map) | |
| Generated constructor for class ss_stmt2pi. | |
| virtual void | gc_mark () |
| Marking routine for class ss_stmt2pi. | |
Private Attributes | |
| srp< ss_function_declaration > | current_function |
| Current function, in which we are transforming to pi. Needed for expression tranformation. When on global scope, current function is set to NULL. | |
| srp< variable_map_type > | local_variable_map |
| Map of variables in current function. | |
| srp< variable_map_type > | namespace_variable_map |
| Map of variables on namespace scope. | |
Static Private Attributes | |
| static ptr< reflection_list > | reflection = reflection |
Definition at line 111 of file ss_ss2pi_base.g.hh.
| lestes::lang::cplus::sem::ss_stmt2pi::ss_stmt2pi | ( | ptr< ss_function_declaration > | a__ss_stmt2pi__current_function, | |
| ptr< variable_map_type > | a__ss_stmt2pi__local_variable_map, | |||
| ptr< variable_map_type > | a__ss_stmt2pi__namespace_variable_map | |||
| ) | [protected] |
Generated constructor for class ss_stmt2pi.
Generated constructor for class ss_stmt2pi.
Definition at line 96 of file ss_ss2pi_base.g.cc.
Referenced by create().
00099 : ss_statement_visitor(), current_function(a__ss_stmt2pi__current_function), local_variable_map(a__ss_stmt2pi__local_variable_map), namespace_variable_map(checked(a__ss_stmt2pi__namespace_variable_map)) 00100 {}
| ptr< ss_function_declaration > lestes::lang::cplus::sem::ss_stmt2pi::current_function_get | ( | ) | const |
The method current_function_get returns the value of the field ss_stmt2pi::current_function.
Definition at line 29 of file ss_ss2pi_base.g.cc.
References current_function.
00030 { 00031 return current_function; 00032 }
| void lestes::lang::cplus::sem::ss_stmt2pi::current_function_set | ( | const ptr< ss_function_declaration > & | x | ) |
The method current_function_set sets the field ss_stmt2pi::current_function to the given value.
| [in] | x | The new value to set ss_stmt2pi::current_function to. |
Definition at line 38 of file ss_ss2pi_base.g.cc.
References current_function.
00039 { 00040 ss_stmt2pi::current_function = x; 00041 }
| ptr< variable_map_type > lestes::lang::cplus::sem::ss_stmt2pi::local_variable_map_get | ( | ) | const |
The method local_variable_map_get returns the value of the field ss_stmt2pi::local_variable_map.
Definition at line 47 of file ss_ss2pi_base.g.cc.
References local_variable_map.
00048 { 00049 return local_variable_map; 00050 }
| void lestes::lang::cplus::sem::ss_stmt2pi::local_variable_map_set | ( | const ptr< variable_map_type > & | x | ) |
The method local_variable_map_set sets the field ss_stmt2pi::local_variable_map to the given value.
| [in] | x | The new value to set ss_stmt2pi::local_variable_map to. |
Definition at line 56 of file ss_ss2pi_base.g.cc.
References local_variable_map.
00057 { 00058 ss_stmt2pi::local_variable_map = x; 00059 }
| ptr< variable_map_type > lestes::lang::cplus::sem::ss_stmt2pi::namespace_variable_map_get | ( | ) | const |
The method namespace_variable_map_get returns the value of the field ss_stmt2pi::namespace_variable_map.
Definition at line 65 of file ss_ss2pi_base.g.cc.
References namespace_variable_map.
00066 { 00067 return namespace_variable_map; 00068 }
| void lestes::lang::cplus::sem::ss_stmt2pi::namespace_variable_map_set | ( | const ptr< variable_map_type > & | x | ) |
The method namespace_variable_map_set sets the field ss_stmt2pi::namespace_variable_map to the given value.
| [in] | x | The new value to set ss_stmt2pi::namespace_variable_map to. |
Definition at line 74 of file ss_ss2pi_base.g.cc.
References namespace_variable_map.
00075 { 00076 ss_stmt2pi::namespace_variable_map = x; 00077 }
| void lestes::lang::cplus::sem::ss_stmt2pi::mem_variable_set | ( | ptr< ss_declaration > | , | |
| ptr< ::lestes::backend_v2::intercode::pi_mem_factory > | ||||
| ) |
API to store record of memmory placeholder for variable. It automaticaly distinguishes between global scope and local scope, where record shall be added (according to "current_function" member).
| ptr< pi_mem_factory > lestes::lang::cplus::sem::ss_stmt2pi::mem_variable_get | ( | ptr< ss_declaration > | x | ) |
API to look-up memory placeholder, which was allocated for variable. It searches in both local and global scope. It also automaticaly inserts new record for alias and function parameter declarations.
This code presumes, there si no ss_fake_declaration on namespace scope.
Definition at line 1492 of file ss_ss2pi_base.cc.
References lestes::lang::cplus::sem::ss_decl2mem::create().
01492 { 01493 //dumb(x); 01494 //try to find on namespace scope firstly 01495 01496 variable_map_type::iterator it = (*namespace_variable_map).find(x); 01497 if ( it != (*namespace_variable_map).end()) 01498 return (*it).second; 01499 01500 //try to find on a local scope 01501 01502 it = (*local_variable_map).find(x); 01503 if ( it != (*local_variable_map).end() ) 01504 return (*it).second; 01505 01506 else { //not yet searched funcall parameter or alias declaration 01507 ptr< pi_mem_factory > res = ss_decl2mem::create(this)->get_real_decl_mem(x); 01508 if (res) (*local_variable_map)[x]=res; 01509 return res; 01510 } //else 01511 01512 return NULL; //doesnt exists 01513 }
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_compound_stmt | ( | ptr< ::lestes::lang::cplus::sem::ss_compound_stmt > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_decl_stmt | ( | ptr< ::lestes::lang::cplus::sem::ss_decl_stmt > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_try | ( | ptr< ::lestes::lang::cplus::sem::ss_try > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_break | ( | ptr< ::lestes::lang::cplus::sem::ss_break > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_return | ( | ptr< ::lestes::lang::cplus::sem::ss_return > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_goto | ( | ptr< ::lestes::lang::cplus::sem::ss_goto > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_expr_stmt | ( | ptr< ::lestes::lang::cplus::sem::ss_expr_stmt > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_continue | ( | ptr< ::lestes::lang::cplus::sem::ss_continue > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_if_stmt | ( | ptr< ::lestes::lang::cplus::sem::ss_if_stmt > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_catch | ( | ptr< ::lestes::lang::cplus::sem::ss_catch > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_switch_stmt | ( | ptr< ::lestes::lang::cplus::sem::ss_switch_stmt > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_do | ( | ptr< ::lestes::lang::cplus::sem::ss_do > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_while | ( | ptr< ::lestes::lang::cplus::sem::ss_while > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| virtual void lestes::lang::cplus::sem::ss_stmt2pi::visit_ss_for | ( | ptr< ::lestes::lang::cplus::sem::ss_for > | ) | [virtual] |
Implements lestes::lang::cplus::sem::ss_statement_visitor.
| ptr< ss_stmt2pi > lestes::lang::cplus::sem::ss_stmt2pi::create | ( | ptr< ss_function_declaration > | a__ss_stmt2pi__current_function, | |
| ptr< variable_map_type > | a__ss_stmt2pi__local_variable_map, | |||
| ptr< variable_map_type > | a__ss_stmt2pi__namespace_variable_map | |||
| ) | [static] |
First generated factory method for class ss_stmt2pi.
This factory method for class ss_stmt2pi takes values of all fields as arguments.
Definition at line 83 of file ss_ss2pi_base.g.cc.
References ss_stmt2pi().
00086 { 00087 return ptr< ss_stmt2pi > ( new ss_stmt2pi(a__ss_stmt2pi__current_function, 00088 a__ss_stmt2pi__local_variable_map, 00089 a__ss_stmt2pi__namespace_variable_map) ); 00090 }
| ptr< object::reflection_list > lestes::lang::cplus::sem::ss_stmt2pi::reflection_get | ( | ) | const [virtual] |
for purposes of dumping
Reimplemented from lestes::lang::cplus::sem::ss_statement_visitor.
Definition at line 102 of file ss_ss2pi_base.g.cc.
References lestes::std::list< T >::create(), reflection, and lestes::lang::cplus::sem::ss_statement_visitor::reflection_get().
00103 { 00104 if (!reflection) { 00105 typedef class_reflection::field_metadata md; 00106 typedef class_reflection::field_metadata_list mdlist; 00107 ptr<mdlist> mdl = mdlist::create(); 00108 mdl->push_back( md::create( "current_function", "ss_function_declaration" ) ); 00109 mdl->push_back( md::create( "local_variable_map", "variable_map_type" ) ); 00110 mdl->push_back( md::create( "namespace_variable_map", "variable_map_type" ) ); 00111 reflection = reflection_list::create( ss_statement_visitor::reflection_get() ); 00112 reflection->push_back( class_reflection::create( "ss_stmt2pi", mdl ) ); 00113 } 00114 return reflection; 00115 }
| ptr< object::field_list_list > lestes::lang::cplus::sem::ss_stmt2pi::field_values_get | ( | ) | const [virtual] |
for purposes of dumping
Reimplemented from lestes::lang::cplus::sem::ss_statement_visitor.
Definition at line 117 of file ss_ss2pi_base.g.cc.
References lestes::std::list< T >::create(), and lestes::lang::cplus::sem::ss_statement_visitor::field_values_get().
00118 { 00119 ptr < field_list_list > result = ss_statement_visitor::field_values_get(); 00120 result->push_back( value_list::create() ); 00121 result->back()->push_back( this->current_function ); 00122 result->push_back( value_list::create() ); 00123 result->back()->push_back( this->local_variable_map ); 00124 result->push_back( value_list::create() ); 00125 result->back()->push_back( this->namespace_variable_map ); 00126 return result; 00127 }
| void lestes::lang::cplus::sem::ss_stmt2pi::gc_mark | ( | void | ) | [protected, virtual] |
Marking routine for class ss_stmt2pi.
Marking routine is used for garbage collection.
Reimplemented from lestes::lang::cplus::sem::ss_statement_visitor.
Definition at line 134 of file ss_ss2pi_base.g.cc.
References lestes::lang::cplus::sem::ss_statement_visitor::gc_mark().
00135 { 00136 ss_statement_visitor::gc_mark(); 00137 }
Current function, in which we are transforming to pi. Needed for expression tranformation. When on global scope, current function is set to NULL.
Definition at line 191 of file ss_ss2pi_base.g.hh.
Referenced by current_function_get(), and current_function_set().
Map of variables in current function.
We distinguish these variables, from global, because after transformation of the current function, they are of no use.
Definition at line 199 of file ss_ss2pi_base.g.hh.
Referenced by local_variable_map_get(), and local_variable_map_set().
Map of variables on namespace scope.
Definition at line 201 of file ss_ss2pi_base.g.hh.
Referenced by namespace_variable_map_get(), and namespace_variable_map_set().
ptr< object::reflection_list > lestes::lang::cplus::sem::ss_stmt2pi::reflection = reflection [static, private] |
Reimplemented from lestes::lang::cplus::sem::ss_statement_visitor.
Definition at line 202 of file ss_ss2pi_base.g.hh.
Referenced by reflection_get().
1.5.1-20070107