Re: Re: fnmatch.c includes alloca.h conditionally?

Derek Robert Price <[email protected]> Mon, 17 May 2004 14:19:19 -0400
Newsgroups gmane.comp.lib.gnulib.bugs,gmane.comp.version-control.cvs.bugs
Organization Ximbiot <http://ximbiot.com>
Message-ID <[email protected]>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Derek Robert Price wrote:

> >Similar stylistic cleanups are possible in argp too, now that
> >"#include <alloca.h>" always works (if you assume the alloca module).
> >I don't have time to pursue this right now, though.
>
>
> Patch attached.
>
> 2004-05-17  Derek R. Price  <[email protected]>
>
>     * lib/argp-help.c, lib/argp-parse.c: Assume <alloca.h> rather than
> freecoding.
>     * modules/argp: Depend on alloca.


Patch really attached this time.

Derek
- --
                *8^)

Email: [email protected]

Get CVS support at <http://ximbiot.com>!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFAqQIlLD1OTBfyMaQRAj6fAJ0ajyvHfzHALxRQYBJBy6rrYfw0XwCgp5x8
mtXUfB+j/JB1lqoB4dDKeFY=
=GrOC
-----END PGP SIGNATURE-----

_______________________________________________
Bug-gnulib mailing list
[email protected]
http://mail.gnu.org/mailman/listinfo/bug-gnulib
09argp-alloca-cleanup.diff (text/plain, 1.8 KB)
Index: lib/argp-help.c
===================================================================
RCS file: /cvsroot/gnulib/gnulib/lib/argp-help.c,v
retrieving revision 1.8
diff -u -p -r1.8 argp-help.c
--- lib/argp-help.c	4 Apr 2004 13:32:34 -0000	1.8
+++ lib/argp-help.c	17 May 2004 13:22:29 -0000
@@ -25,21 +25,7 @@
 #include <config.h>
 #endif
 
-/* AIX requires this to be the first thing in the file.  */
-#ifndef __GNUC__
-# if HAVE_ALLOCA_H || defined _LIBC
-#  include <alloca.h>
-# else
-#  ifdef _AIX
-#pragma alloca
-#  else
-#   ifndef alloca /* predefined by HP cc +Olibcalls */
-char *alloca ();
-#   endif
-#  endif
-# endif
-#endif
-
+#include <alloca.h>
 #include <stddef.h>
 #include <stdlib.h>
 #include <string.h>
Index: lib/argp-parse.c
===================================================================
RCS file: /cvsroot/gnulib/gnulib/lib/argp-parse.c,v
retrieving revision 1.7
diff -u -p -r1.7 argp-parse.c
--- lib/argp-parse.c	9 Mar 2004 19:42:23 -0000	1.7
+++ lib/argp-parse.c	17 May 2004 13:22:30 -0000
@@ -21,21 +21,7 @@
 #include <config.h>
 #endif
 
-/* AIX requires this to be the first thing in the file.  */
-#ifndef __GNUC__
-# if HAVE_ALLOCA_H || defined _LIBC
-#  include <alloca.h>
-# else
-#  ifdef _AIX
-#pragma alloca
-#  else
-#   ifndef alloca /* predefined by HP cc +Olibcalls */
-char *alloca ();
-#   endif
-#  endif
-# endif
-#endif
-
+#include <alloca.h>
 #include <stdlib.h>
 #include <string.h>
 #include <unistd.h>
Index: modules/argp
===================================================================
RCS file: /cvsroot/gnulib/gnulib/modules/argp,v
retrieving revision 1.4
diff -u -p -r1.4 argp
--- modules/argp	4 May 2004 18:39:43 -0000	1.4
+++ modules/argp	17 May 2004 13:22:30 -0000
@@ -17,6 +17,7 @@ lib/argp-xinl.c
 m4/argp.m4
 
 Depends-on:
+alloca
 getopt
 strchrnul
 sysexits