--- trunk/mdtools/BASS_parse/parse_tree.c 2002/07/09 18:40:59 11 +++ trunk/mdtools/BASS_parse/parse_tree.c 2002/10/16 21:07:02 138 @@ -3,6 +3,11 @@ void walk_down( struct node_tag* the_node, struct name #include "parse_tree.h" +#ifdef IS_MPI +#define __is_lex__ +#include "../headers/mpiBASS.h" +#endif + void walk_down( struct node_tag* the_node, struct namespc the_namespc ); int mol_index; // keeps track of the number of molecules int comp_index; // keeps track of the number of components. @@ -27,7 +32,8 @@ void pt_me( struct node_tag* head_node ){ mol_index = 0; comp_index = 0; - walk_down( head_node->next_stmt, global_namespc ); + walk_down( head_node->next_stmt, global_namespc ); // closed global namespace + exit + } /* @@ -224,7 +230,7 @@ void walk_down( struct node_tag* the_node, struct name exit(0); } - init_start_index( the_node, the_namespc ); + //init_start_index( the_node, the_namespc ); break; default: @@ -332,19 +338,19 @@ void print_tree_error( struct node_tag* err_node, char case STR_ASSN: fprintf( stderr, "%s", - err_node->the_data.asmt.rhs ); + err_node->the_data.asmt.rhs.str_ptr ); break; case INT_ASSN: fprintf( stderr, "%d", - err_node->the_data.asmt.rhs ); + err_node->the_data.asmt.rhs.i_val ); break; case DOUBLE_ASSN: fprintf( stderr, "%lf", - err_node->the_data.asmt.rhs ); + err_node->the_data.asmt.rhs.d_val ); break; } @@ -358,6 +364,9 @@ void print_tree_error( struct node_tag* err_node, char fprintf( stderr, "Parse tree error: position node error => ( %lf, %lf, %lf )\n" " -> %s\n", + err_node->the_data.pos.x, + err_node->the_data.pos.y, + err_node->the_data.pos.z, err_msg ); break; @@ -365,6 +374,9 @@ void print_tree_error( struct node_tag* err_node, char fprintf( stderr, "Parse tree error: orientation node error => ( %lf, %lf, %lf )\n" " -> %s\n", + err_node->the_data.ort.x, + err_node->the_data.ort.y, + err_node->the_data.ort.z, err_msg ); break; @@ -380,6 +392,11 @@ void print_tree_error( struct node_tag* err_node, char "Parse tree error: unknown node type -> %s\n", err_msg ); } + +#ifdef IS_MPI + mpiInterfaceExit(); +#endif + }