AMD autodetection extended
[libfirm] / ir / obstack_win / obstack.c
index 2c82bf8..ae6e2a5 100644 (file)
@@ -39,7 +39,8 @@
    program understand `configure --with-gnu-libc' and omit the object
    files, it is simpler to just do this in the source for each such file.  */
 
-#include <stdio.h>             /* Random thing to get __GNU_LIBRARY__.  */
+/* Random thing to get __GNU_LIBRARY__.  */
+#include <stdio.h>
 #if !defined (_LIBC) && defined (__GNU_LIBRARY__) && __GNU_LIBRARY__ > 1
 #include <gnu-versions.h>
 #if _GNU_OBSTACK_INTERFACE_VERSION == OBSTACK_INTERFACE_VERSION
@@ -146,8 +147,7 @@ struct obstack *_obstack;
    To recover from an out of memory error,
    free up some memory, then call this again.  */
 
-int
-_obstack_begin (h, size, alignment, chunkfun, freefun)
+int _obstack_begin(h, size, alignment, chunkfun, freefun)
      struct obstack *h;
      int size;
      int alignment;
@@ -204,8 +204,7 @@ _obstack_begin (h, size, alignment, chunkfun, freefun)
   return 1;
 }
 
-int
-_obstack_begin_1 (h, size, alignment, chunkfun, freefun, arg)
+int _obstack_begin_1 (h, size, alignment, chunkfun, freefun, arg)
      struct obstack *h;
      int size;
      int alignment;
@@ -270,14 +269,13 @@ _obstack_begin_1 (h, size, alignment, chunkfun, freefun, arg)
    Copies any partial object from the end of the old chunk
    to the beginning of the new one.  */
 
-void
-_obstack_newchunk (h, length)
+void _obstack_newchunk (h, length)
      struct obstack *h;
      int length;
 {
   register struct _obstack_chunk *old_chunk = h->chunk;
   register struct _obstack_chunk *new_chunk;
-  register long        new_size;
+  register long new_size;
   register long obj_size = h->next_free - h->object_base;
   register long i;
   long already;
@@ -340,13 +338,12 @@ _obstack_newchunk (h, length)
 int _obstack_allocated_p (struct obstack *h, POINTER obj);
 #endif
 
-int
-_obstack_allocated_p (h, obj)
+int _obstack_allocated_p (h, obj)
      struct obstack *h;
      POINTER obj;
 {
-  register struct _obstack_chunk *lp;  /* below addr of any objects in this chunk */
-  register struct _obstack_chunk *plp; /* point to previous chunk if any */
+  register struct _obstack_chunk *lp;   /* below addr of any objects in this chunk */
+  register struct _obstack_chunk *plp;  /* point to previous chunk if any */
 
   lp = (h)->chunk;
   /* We use >= rather than > since the object cannot be exactly at
@@ -368,13 +365,12 @@ _obstack_allocated_p (h, obj)
 /* This function has two names with identical definitions.
    This is the first one, called from non-ANSI code.  */
 
-void
-_obstack_free (h, obj)
+void _obstack_free (h, obj)
      struct obstack *h;
      POINTER obj;
 {
-  register struct _obstack_chunk *lp;  /* below addr of any objects in this chunk */
-  register struct _obstack_chunk *plp; /* point to previous chunk if any */
+  register struct _obstack_chunk *lp;   /* below addr of any objects in this chunk */
+  register struct _obstack_chunk *plp;  /* point to previous chunk if any */
 
   lp = h->chunk;
   /* We use >= because there cannot be an object at the beginning of a chunk.
@@ -402,13 +398,12 @@ _obstack_free (h, obj)
 
 /* This function is used from ANSI code.  */
 
-void
-obstack_free (h, obj)
+void obstack_free (h, obj)
      struct obstack *h;
      POINTER obj;
 {
-  register struct _obstack_chunk *lp;  /* below addr of any objects in this chunk */
-  register struct _obstack_chunk *plp; /* point to previous chunk if any */
+  register struct _obstack_chunk *lp;   /* below addr of any objects in this chunk */
+  register struct _obstack_chunk *plp;  /* point to previous chunk if any */
 
   lp = h->chunk;
   /* We use >= because there cannot be an object at the beginning of a chunk.
@@ -434,8 +429,7 @@ obstack_free (h, obj)
     abort ();
 }
 
-int
-_obstack_memory_used (h)
+int _obstack_memory_used (h)
      struct obstack *h;
 {
   register struct _obstack_chunk* lp;
@@ -460,8 +454,7 @@ _obstack_memory_used (h)
 # endif
 #endif
 
-static void
-print_and_abort ()
+static void print_and_abort(void)
 {
   fputs (_("memory exhausted\n"), stderr);
   exit (obstack_exit_failure);
@@ -589,4 +582,4 @@ POINTER (obstack_copy0) (obstack, pointer, length)
 
 #endif /* 0 */
 
-#endif /* !ELIDE_CODE */
+#endif    /* !ELIDE_CODE */