[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: alloca in HP NonStop

From: Paul Eggert
Subject: Re: alloca in HP NonStop
Date: Mon, 02 Jul 2012 17:37:34 -0700
User-agent: Mozilla/5.0 (X11; Linux i686; rv:13.0) Gecko/20120615 Thunderbird/13.0.1

On 06/28/2012 09:41 AM, Joachim Schmitz wrote:
> Or drop it an just take the else branch.

Yes, that sounds simpler.  Also, how about the following
ideas for simplification:

Don't bother checking __TANDEM; _TNS_E_TARGET should suffice.
This fixes what appears to be a bug on older Tandem systems.

Don't define _BUILTIN (couldn't see why this mattered).

Omit most comments (not really needed here; it's pretty

Use GNU style (space before paren) in pragma.

In short, how about the following patch instead?

 ChangeLog       |    7 +++++++
 lib/alloca.in.h |    7 +++++++
 2 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index e7f7883..979d18a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2012-07-02  Paul Eggert  <address@hidden>
+       alloca: add support for HP NonStop TNS/E native
+       * lib/alloca.in.h (alloca): Support the new host.
+       From a suggestion by Joachim Schmitz in
+       <http://lists.gnu.org/archive/html/bug-gnulib/2012-06/msg00355.html>.
 2012-07-02  Pádraig Brady  <address@hidden>
        fsusage: remove code not needed on non GNU/Linux systems.
diff --git a/lib/alloca.in.h b/lib/alloca.in.h
index 99be048..0f5ce34 100644
--- a/lib/alloca.in.h
+++ b/lib/alloca.in.h
@@ -42,6 +42,13 @@
 # elif defined _MSC_VER
 #  include <malloc.h>
 #  define alloca _alloca
+# elif defined _TNS_E_TARGET /* HP NonStop TNS/E native */
+#  ifdef  __cplusplus
+    extern "C"
+#  endif
+   void *_alloca (unsigned short);
+#  pragma intrinsic (_alloca)
+#  define alloca _alloca
 # elif defined __DECC && defined __VMS
 #  define alloca __ALLOCA
 # else

reply via email to

[Prev in Thread] Current Thread [Next in Thread]