absyntax_utils/search_var_instance_decl.cc
changeset 706 31553c22f318
parent 625 c0bda77b37a0
child 793 268bf4ca5fa1
equal deleted inserted replaced
705:f2323f79252e 706:31553c22f318
   142   return ((typeid( *(decl) ) == typeid( array_specification_c                )) ||
   142   return ((typeid( *(decl) ) == typeid( array_specification_c                )) ||
   143 //        (typeid( *(decl) ) == typeid( array_spec_init_c                    )) ||  /* does not seem to be necessary */
   143 //        (typeid( *(decl) ) == typeid( array_spec_init_c                    )) ||  /* does not seem to be necessary */
   144           (typeid( *(decl) ) == typeid( structure_type_declaration_c         )) ||  
   144           (typeid( *(decl) ) == typeid( structure_type_declaration_c         )) ||  
   145           (typeid( *(decl) ) == typeid( structure_element_declaration_list_c )) ||
   145           (typeid( *(decl) ) == typeid( structure_element_declaration_list_c )) ||
   146 //        (typeid( *(decl) ) == typeid( structure_type_declaration_c         )) ||  /* does not seem to be necessary */
   146 //        (typeid( *(decl) ) == typeid( structure_type_declaration_c         )) ||  /* does not seem to be necessary */
   147           (typeid( *(decl) ) == typeid( initialized_structure_c              ))
   147           (typeid( *(decl) ) == typeid( initialized_structure_c              )) ||
   148           
   148           (search_base_type.type_is_fb(decl) && current_vartype == external_vt)
   149          );
   149          );
   150 }
   150 }
   151 
   151 
   152 
   152 bool search_var_instance_decl_c::type_is_fb(symbol_c *symbol) {
       
   153     symbol_c *decl;
       
   154     search_base_type_c search_base_type;
       
   155 
       
   156     decl = this->get_decl(symbol);
       
   157     if (NULL == decl) ERROR;
       
   158     return search_base_type.type_is_fb(decl);
       
   159 }
   153 
   160 
   154 /***************************/
   161 /***************************/
   155 /* B 0 - Programming Model */
   162 /* B 0 - Programming Model */
   156 /***************************/
   163 /***************************/
   157 void *search_var_instance_decl_c::visit(library_c *symbol) {
   164 void *search_var_instance_decl_c::visit(library_c *symbol) {