Expr Ast_Def::_parse_in( ParsingContext &context ) const { std::set<String> res; if ( context.parent ) { std::set<String> avail; avail.insert( name ); get_potentially_needed_ext_vars( res, avail ); } // Def *c = new Def( this ); // SI64 ptr = SI64( ST( c ) ); Expr out = room( cst( ip->type_Def, 64, &ptr ) ); out->flags |= Inst::SURDEF; if ( stat ) out->flags |= Inst::STATIC; return context.reg_var( name, out, true ); }
Expr Ast_Class::_parse_in( ParsingContext &context ) const { std::set<String> res; if ( context.parent ) { std::set<String> avail; avail.insert( name ); get_potentially_needed_ext_vars( res, avail ); } // Class *c = 0; #define DECL_BT( T ) if ( name == #T ) { c = ip->class_##T; c->ast_item = this; } #include "../Ssa/DeclBaseClass.h" #include "../Ssa/DeclParmClass.h" #undef DECL_BT if ( not c ) c = new Class( this ); // SI64 ptr = SI64( ST( c ) ); Expr val = cst( ip->type_Class, 64, &ptr ); Expr out = room( val ); out->flags |= Inst::SURDEF; return context.reg_var( name, out, true ); }