public inbox for gas2@sourceware.org
 help / color / mirror / Atom feed
From: Don Bowman <bowman@waterloo.hp.com>
To: gas2@cygnus.com
Subject: Diff for as.h in gas to compile on hpux
Date: Mon, 13 May 1996 15:05:00 -0000	[thread overview]
Message-ID: <199605132205.AA155435102@hppadap.waterloo.hp.com> (raw)

The change is actually neither mips nor hpux specific: notably,
the assert-mask had an odd-format I did not understand:

#define assert(p) ((P) ? 0 : (as_assert (...)))

which meant it evaluated to be 0, or the return of as_assert(),
instead of void.

The hp-ux 9.05 c-compiler did not like one of the uses of this,
which became:

 (blah) ? 0 : as_assert();

 or 0; after optimisation

The following diff against as.h just changes the assert macro
to be an if statement.


*** as.h@@/main/LATEST	Fri Mar 22 11:44:19 1996
--- as.h	Mon May 13 17:25:50 1996
***************
*** 121,127 ****
  
  #else
  
! #define assert(P) ((P) ? 0 : (as_assert (__FILE__, __LINE__, __PRETTY_FUNCTION__), 0))
  #undef abort
  #define abort()		as_abort (__FILE__, __LINE__, __PRETTY_FUNCTION__)
  
--- 121,127 ----
  
  #else
  
! #define assert(P) if (P) (as_assert (__FILE__, __LINE__, __PRETTY_FUNCTION__), 0)
  #undef abort
  #define abort()		as_abort (__FILE__, __LINE__, __PRETTY_FUNCTION__)
  

--
 Don Bowman        **      bowman@waterloo.hp.com     **           519-883-3019 


                 reply	other threads:[~1996-05-13 15:05 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=199605132205.AA155435102@hppadap.waterloo.hp.com \
    --to=bowman@waterloo.hp.com \
    --cc=gas2@cygnus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).