=================================================================== RCS file: /home/cvs/OpenXM_contrib2/asir2000/parse/debug.c,v retrieving revision 1.16 retrieving revision 1.18 diff -u -p -r1.16 -r1.18 --- OpenXM_contrib2/asir2000/parse/debug.c 2006/02/08 02:11:19 1.16 +++ OpenXM_contrib2/asir2000/parse/debug.c 2006/02/28 08:36:39 1.18 @@ -45,7 +45,7 @@ * DEVELOPER SHALL HAVE NO LIABILITY IN CONNECTION WITH THE USE, * PERFORMANCE OR NON-PERFORMANCE OF THE SOFTWARE. * - * $OpenXM: OpenXM_contrib2/asir2000/parse/debug.c,v 1.15 2003/05/14 07:08:48 noro Exp $ + * $OpenXM: OpenXM_contrib2/asir2000/parse/debug.c,v 1.17 2006/02/25 06:33:31 noro Exp $ */ #include "ca.h" #include "parse.h" @@ -842,12 +842,14 @@ void showpos_to_string(char *buf) /* [[file,line,name],...] */ +extern int at_root; + void showpos_to_list(LIST *r) { NODE n,u,u1,t; VS vs; - STRING null,name,fname; - LIST l; + STRING null,name,fname,kwd; + LIST l,b; Q q; u = 0; @@ -871,7 +873,14 @@ void showpos_to_list(LIST *r) MKNODE(u1,l,u); u = u1; } } - MKLIST(*r,u); + /* line number at the toplevel */ + MKSTR(fname,"toplevel"); STOQ(at_root,q); + t = mknode(2,fname,q); MKLIST(l,t); MKNODE(u1,l,u); u = u1; + MKLIST(b,u); + + MKSTR(kwd,"asir_where"); + t = mknode(2,kwd,b); + MKLIST(*r,t); } void change_stack(int level,NODE *pvss)