]> git.saurik.com Git - bison.git/commitdiff
* src/print_graph.c (node_output_size): Declared POSIX `size_t' type,
authorMarc Autret <autret_m@epita.fr>
Fri, 24 Aug 2001 18:47:20 +0000 (18:47 +0000)
committerMarc Autret <autret_m@epita.fr>
Fri, 24 Aug 2001 18:47:20 +0000 (18:47 +0000)
instead of `unsigned'.
(print_state): Donnot call obstack_object_size () in obstack_grow ()
to avoid macro variables shadowing.

ChangeLog
src/print_graph.c

index fdeda1882ab9a9e5d211ebcb24c32d3b3de40134..359dd5b9346d5236acc2ed7a7459581af2593243 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-08-24  Marc Autret  <autret_m@epita.fr>
+
+       * src/print_graph.c (node_output_size): Declared POSIX `size_t' type, 
+       instead of `unsigned'.
+       (print_state): Donnot call obstack_object_size () in obstack_grow ()
+       to avoid macro variables shadowing.
+
 2001-08-23  Marc Autret  <autret_m@epita.fr>
 
        * src/lex.c (percent_table): Typo: s/naem/name/.
 2001-08-23  Marc Autret  <autret_m@epita.fr>
 
        * src/lex.c (percent_table): Typo: s/naem/name/.
index 5dca0920008cd18057173f1ae6ce153c60f70424..c2067744a95a27e16a7d1b88a39562dc275c96fc 100644 (file)
@@ -36,7 +36,7 @@
 
 static graph_t graph;
 
 
 static graph_t graph;
 
-static unsigned node_output_size = 0;
+static size_t node_output_size = 0;
 
 /* Return an unambiguous printable representated, allocated in slot 0,
    for NAME, suitable for C strings.  */
 
 /* Return an unambiguous printable representated, allocated in slot 0,
    for NAME, suitable for C strings.  */
@@ -246,10 +246,15 @@ print_state (int state)
   }
   
   /* `obstack_cat' NODE_OBSTACK to GRAPH_OBSTACK.  */
   }
   
   /* `obstack_cat' NODE_OBSTACK to GRAPH_OBSTACK.  */
-  obstack_grow (&graph_obstack, 
-               obstack_base (&node_obstack), 
-               obstack_object_size (&node_obstack));
-  obstack_finish (&node_obstack);
+  {
+    size_t obs_size;
+
+    obs_size = obstack_object_size (&node_obstack);
+    obstack_grow (&graph_obstack, 
+                 obstack_base (&node_obstack), 
+                 obs_size);
+    obstack_finish (&node_obstack);
+  }
 }
 \f
 
 }
 \f