/[m4]/m4/m4/debug.c
ViewVC logotype

Diff of /m4/m4/debug.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by gary, Thu Sep 20 03:48:05 2001 UTC revision 1.7 by gary, Sun Sep 30 14:43:38 2001 UTC
# Line 44  m4_debug_init (void) Line 44  m4_debug_init (void)
44    obstack_init (&trace);    obstack_init (&trace);
45  }  }
46    
 void  
 m4_debug_exit (void)  
 {  
   obstack_free (&trace, NULL);  
 }  
   
47    
48    
49  /* Function to decode the debugging flags OPTS.  Used by main while  /* Function to decode the debugging flags OPTS.  Used by main while
# Line 326  m4_trace_prepre (const char *name, int i Line 320  m4_trace_prepre (const char *name, int i
320  /* Format the parts of a trace line, that can be made before the macro is  /* Format the parts of a trace line, that can be made before the macro is
321     actually expanded.  Used from expand_macro ().  */     actually expanded.  Used from expand_macro ().  */
322  void  void
323  m4_trace_pre (const char *name, int id, int argc, m4_symbol **argv)  m4_trace_pre (const char *name, int id, int argc, m4_token_data **argv)
324  {  {
325    int i;    int i;
326    const m4_builtin *bp;    const m4_builtin *bp;
# Line 343  m4_trace_pre (const char *name, int id, Line 337  m4_trace_pre (const char *name, int id,
337            if (i != 1)            if (i != 1)
338              m4_trace_format (", ");              m4_trace_format (", ");
339    
340            switch (M4_SYMBOL_TYPE (argv[i]))            switch (M4_TOKEN_DATA_TYPE (argv[i]))
341              {              {
342              case M4_TOKEN_TEXT:              case M4_TOKEN_TEXT:
343                m4_trace_format ("%l%S%r", M4_SYMBOL_TEXT (argv[i]));                m4_trace_format ("%l%S%r", M4_TOKEN_DATA_TEXT (argv[i]));
344                break;                break;
345    
346              case M4_TOKEN_FUNC:              case M4_TOKEN_FUNC:
347                bp = m4_builtin_find_by_func (NULL, M4_SYMBOL_FUNC (argv[i]));                bp = m4_builtin_find_by_func (NULL, M4_TOKEN_DATA_FUNC(argv[i]));
348                if (bp == NULL)                if (bp == NULL)
349                  {                  {
350                    M4ERROR ((warning_status, 0, _("\                    M4ERROR ((warning_status, 0, _("\
# Line 380  INTERNAL ERROR: Bad token data type (m4_ Line 374  INTERNAL ERROR: Bad token data type (m4_
374  /* Format the final part of a trace line and print it all.  Used from  /* Format the final part of a trace line and print it all.  Used from
375     expand_macro ().  */     expand_macro ().  */
376  void  void
377  m4_trace_post (const char *name, int id, int argc, m4_symbol **argv,  m4_trace_post (const char *name, int id, int argc, m4_token_data **argv,
378              const char *expanded)              const char *expanded)
379  {  {
380    if (debug_level & M4_DEBUG_TRACE_CALL)    if (debug_level & M4_DEBUG_TRACE_CALL)

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26