This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Alternate booleans patch
- To: gcc-patches at gcc dot gnu dot org
- Subject: Alternate booleans patch
- From: "Zack Weinberg" <zackw at stanford dot edu>
- Date: Tue, 27 Feb 2001 22:15:48 -0800
People seem to like TRUE and FALSE. This patch keeps them, but gets
the definitions out of the xm-*.h files (fifty separate instances!)
It also provides us with a universal definition of a 'bool' type,
which is the C99 _Bool if available. We had a couple of private
definitions floating around. You can use TRUE and FALSE or true and
false as boolean constants.
Most of the patch is renaming variables named 'true' and 'false', and
squelching users of hash.h's "boolean". I did fix the Fortran front
end this time.
This does not have any unrelated cleanups. Note I left the
copyright-year bumps out.
Will run bootstrap overnight. OK for mainline?
zw
* config/xm-lynx.h, config/xm-std32.h, config/a29k/xm-a29k.h,
config/a29k/xm-unix.h, config/alpha/xm-alpha.h,
config/arc/xm-arc.h, config/arm/xm-arm.h, config/c4x/xm-c4x.h,
config/clipper/xm-clix.h, config/convex/xm-convex.h,
config/d30v/xm-d30v.h, config/dsp16xx/xm-dsp16xx.h,
config/elxsi/xm-elxsi.h, config/fr30/xm-fr30.h,
config/h8300/xm-h8300.h, config/i370/xm-i370.h,
config/i370/xm-linux.h, config/i370/xm-mvs.h,
config/i370/xm-oe.h, config/i386/xm-aix.h,
config/i386/xm-i386.h, config/i386/xm-osf.h,
config/i860/xm-i860.h, config/i960/xm-i960.h,
config/ia64/xm-ia64.h, config/m32r/xm-m32r.h,
config/m68k/xm-m68k.h, config/m88k/xm-m88k.h,
config/mcore/xm-mcore.h, config/mips/xm-mips.h,
config/mn10200/xm-mn10200.h, config/mn10300/xm-mn10300.h,
config/ns32k/xm-ns32k.h, config/pa/xm-linux.h,
config/pa/xm-pa.h, config/pa/xm-pa64hpux.h,
config/pa/xm-pahpux.h, config/pa/xm-papro.h,
config/pj/xm-pj.h, config/romp/xm-romp.h,
config/rs6000/xm-beos.h, config/rs6000/xm-rs6000.h,
config/rs6000/xm-sysv4.h, config/sh/xm-sh.h,
config/sparc/xm-sparc.h, config/sparc/xm-sysv4.h,
config/v850/xm-v850.h, config/vax/xm-vax.h,
config/vax/xm-vms.h, config/we32k/xm-we32k.h:
Do not define TRUE or FALSE.
* config/i386/xm-aix.h, config/i386/xm-osf.h: Delete; made
empty by above change.
* config.gcc: Remove references to these files.
* configure.in: Detect stdbool.h.
* configure, config.in: Regenerate.
* system.h: Include stddef.h here if available. Set
HAVE__BOOL based on GCC_VERSION and __STDC_VERSION__. Then
set up a sensible boolean type at the very end.
* combine.c, cse.c, expr.c, fold-const.c, gensupport.c, f/com.c:
Rename variables named 'true' and/or 'false'.
* hash.h: Delete 'boolean' typedef and related #undefs.
* f/proj.h: Delete 'bool' type. Don't include stddef.h here.
* function.c, ggc-common.c, hash.h, hash.c, tlink.c, cp/decl.c,
java/class.c, java/decl.c, java/java-tree.h:
Replace all uses of 'boolean' with 'bool'.
===================================================================
Index: config/xm-lynx.h
--- config/xm-lynx.h 2001/02/25 05:23:33 1.3
+++ config/xm-lynx.h 2001/02/28 05:59:25
@@ -22,10 +22,6 @@ Boston, MA 02111-1307, USA. */
running Lynx. This file should not be specified as $xm_file itself;
instead $xm_file should be CPU/xm-lynx.h, which should include this one. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* Arguments to use with `exit'. */
#define SUCCESS_EXIT_CODE 0
#define FATAL_EXIT_CODE 33
===================================================================
Index: config/xm-std32.h
--- config/xm-std32.h 1998/12/16 21:00:26 1.2
+++ config/xm-std32.h 2001/02/28 05:59:25
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/a29k/xm-a29k.h
--- config/a29k/xm-a29k.h 1998/12/16 21:00:46 1.2
+++ config/a29k/xm-a29k.h 2001/02/28 05:59:25
@@ -18,11 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/a29k/xm-unix.h
--- config/a29k/xm-unix.h 1998/12/16 21:00:47 1.2
+++ config/a29k/xm-unix.h 2001/02/28 05:59:25
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/alpha/xm-alpha.h
--- config/alpha/xm-alpha.h 2001/02/25 05:23:34 1.9
+++ config/alpha/xm-alpha.h 2001/02/28 05:59:25
@@ -20,11 +20,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/arc/xm-arc.h
--- config/arc/xm-arc.h 1998/12/16 21:01:24 1.2
+++ config/arc/xm-arc.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/arm/xm-arm.h
--- config/arm/xm-arm.h 2001/02/25 05:23:34 1.4
+++ config/arm/xm-arm.h 2001/02/28 05:59:26
@@ -21,10 +21,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
@@ -60,5 +56,3 @@ Boston, MA 02111-1307, USA. */
#endif
/* EOF xm-arm.h */
-
-
===================================================================
Index: config/c4x/xm-c4x.h
--- config/c4x/xm-c4x.h 1998/12/16 21:02:15 1.2
+++ config/c4x/xm-c4x.h 2001/02/28 05:59:26
@@ -1,7 +1,3 @@
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 32
#define HOST_BITS_PER_SHORT 32
@@ -18,4 +14,3 @@
/* Arguments to use with `exit'. */
#define SUCCESS_EXIT_CODE 0
#define FATAL_EXIT_CODE 33
-
===================================================================
Index: config/clipper/xm-clix.h
--- config/clipper/xm-clix.h 2001/02/25 05:23:34 1.3
+++ config/clipper/xm-clix.h 2001/02/28 05:59:26
@@ -1,9 +1,5 @@
/* Config file for Clipper running Clix, system V. 3.2 clone */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* target machine dependencies.
tm.h is a symbolic link to the actual target specific file. */
===================================================================
Index: config/convex/xm-convex.h
--- config/convex/xm-convex.h 2001/02/25 05:23:34 1.3
+++ config/convex/xm-convex.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* target machine dependencies.
tm.h is a symbolic link to the actual target specific file. */
#include "tm.h"
===================================================================
Index: config/d30v/xm-d30v.h
--- config/d30v/xm-d30v.h 2001/02/25 05:23:34 1.4
+++ config/d30v/xm-d30v.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* A C expression for the status code to be returned when the compiler exits
after serious errors. */
#define FATAL_EXIT_CODE 33
===================================================================
Index: config/dsp16xx/xm-dsp16xx.h
--- config/dsp16xx/xm-dsp16xx.h 2000/05/01 17:19:34 1.3
+++ config/dsp16xx/xm-dsp16xx.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/elxsi/xm-elxsi.h
--- config/elxsi/xm-elxsi.h 2000/05/01 17:21:40 1.3
+++ config/elxsi/xm-elxsi.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* target machine dependencies.
tm.h is a symbolic link to the actual target specific file. */
#include "tm.h"
@@ -35,4 +31,3 @@ Boston, MA 02111-1307, USA. */
/* Arguments to use with `exit'. */
#define SUCCESS_EXIT_CODE 0
#define FATAL_EXIT_CODE 33
-
===================================================================
Index: config/fr30/xm-fr30.h
--- config/fr30/xm-fr30.h 2001/02/25 05:23:34 1.2
+++ config/fr30/xm-fr30.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* A C expression for the status code to be returned when the compiler exits
after serious errors. */
#define FATAL_EXIT_CODE 33
===================================================================
Index: config/h8300/xm-h8300.h
--- config/h8300/xm-h8300.h 1998/12/16 21:02:57 1.2
+++ config/h8300/xm-h8300.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
@@ -43,4 +39,3 @@ Boston, MA 02111-1307, USA. */
/* target machine dependencies.
tm.h is a symbolic link to the actual target specific file. */
#include "tm.h"
-
===================================================================
Index: config/i370/xm-i370.h
--- config/i370/xm-i370.h 2001/02/25 05:23:34 1.4
+++ config/i370/xm-i370.h 2001/02/28 05:59:26
@@ -20,11 +20,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
===================================================================
Index: config/i370/xm-linux.h
--- config/i370/xm-linux.h 2001/02/25 05:23:34 1.3
+++ config/i370/xm-linux.h 2001/02/28 05:59:26
@@ -21,13 +21,7 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
-
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
#define HOST_BITS_PER_INT 32
@@ -54,6 +48,5 @@ extern char *alloca ();
#include "tm.h"
/* Arguments to use with `exit'. */
-
#define SUCCESS_EXIT_CODE 0
#define FATAL_EXIT_CODE 12
===================================================================
Index: config/i370/xm-mvs.h
--- config/i370/xm-mvs.h 2001/02/25 05:23:34 1.4
+++ config/i370/xm-mvs.h 2001/02/28 05:59:26
@@ -20,11 +20,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
===================================================================
Index: config/i370/xm-oe.h
--- config/i370/xm-oe.h 2001/02/25 05:23:34 1.5
+++ config/i370/xm-oe.h 2001/02/28 05:59:26
@@ -20,11 +20,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
===================================================================
Index: config/i386/xm-aix.h
--- config/i386/xm-aix.h 1998/12/16 21:05:05 1.2
+++ config/i386/xm-aix.h 2001/02/28 05:59:26
@@ -1,2 +0,0 @@
-#undef TRUE
-#undef FALSE
===================================================================
Index: config/i386/xm-i386.h
--- config/i386/xm-i386.h 2001/01/24 18:40:46 1.4
+++ config/i386/xm-i386.h 2001/02/28 05:59:26
@@ -22,10 +22,6 @@ Boston, MA 02111-1307, USA. */
#define __i386__ 1
#endif
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/i386/xm-osf.h
--- config/i386/xm-osf.h 1998/12/16 21:05:21 1.2
+++ config/i386/xm-osf.h 2001/02/28 05:59:26
@@ -1,2 +0,0 @@
-#undef TRUE
-#undef FALSE
===================================================================
Index: config/i860/xm-i860.h
--- config/i860/xm-i860.h 2001/02/25 05:23:35 1.3
+++ config/i860/xm-i860.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/i960/xm-i960.h
--- config/i960/xm-i960.h 1998/12/16 21:05:59 1.2
+++ config/i960/xm-i960.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/ia64/xm-ia64.h
--- config/ia64/xm-ia64.h 2000/03/17 20:06:49 1.3
+++ config/ia64/xm-ia64.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* A C expression for the status code to be returned when the compiler exits
after serious errors. */
#define FATAL_EXIT_CODE 33
===================================================================
Index: config/m32r/xm-m32r.h
--- config/m32r/xm-m32r.h 1998/12/16 21:06:06 1.2
+++ config/m32r/xm-m32r.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/m68k/xm-m68k.h
--- config/m68k/xm-m68k.h 1998/12/16 21:08:05 1.2
+++ config/m68k/xm-m68k.h 2001/02/28 05:59:26
@@ -18,11 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/m88k/xm-m88k.h
--- config/m88k/xm-m88k.h 2000/02/26 21:33:39 1.6
+++ config/m88k/xm-m88k.h 2001/02/28 05:59:26
@@ -20,11 +20,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/mcore/xm-mcore.h
--- config/mcore/xm-mcore.h 2000/02/14 22:51:36 1.1
+++ config/mcore/xm-mcore.h 2001/02/28 05:59:26
@@ -17,10 +17,6 @@ You should have received a copy of the G
along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
@@ -39,4 +35,3 @@ the Free Software Foundation, 675 Mass A
/* Arguments to use with `exit'. */
#define SUCCESS_EXIT_CODE 0
#define FATAL_EXIT_CODE 33
-
===================================================================
Index: config/mips/xm-mips.h
--- config/mips/xm-mips.h 2001/02/25 05:23:37 1.6
+++ config/mips/xm-mips.h 2001/02/28 05:59:26
@@ -19,11 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/mn10200/xm-mn10200.h
--- config/mn10200/xm-mn10200.h 1999/09/07 05:48:49 1.3
+++ config/mn10200/xm-mn10200.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/mn10300/xm-mn10300.h
--- config/mn10300/xm-mn10300.h 1999/09/07 05:48:51 1.3
+++ config/mn10300/xm-mn10300.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/ns32k/xm-ns32k.h
--- config/ns32k/xm-ns32k.h 2000/01/27 19:20:51 1.3
+++ config/ns32k/xm-ns32k.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* target machine dependencies.
tm.h is a symbolic link to the actual target specific file. */
#include "tm.h"
===================================================================
Index: config/pa/xm-linux.h
--- config/pa/xm-linux.h 2001/02/28 02:53:45 1.3
+++ config/pa/xm-linux.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/pa/xm-pa.h
--- config/pa/xm-pa.h 2001/02/28 02:53:45 1.5
+++ config/pa/xm-pa.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/pa/xm-pa64hpux.h
--- config/pa/xm-pa64hpux.h 2000/07/17 06:16:14 1.2
+++ config/pa/xm-pa64hpux.h 2001/02/28 05:59:26
@@ -22,11 +22,6 @@ Boston, MA 02111-1307, USA. */
/* HP-UX is a flavor of System V */
#define USG
-/* Use System V memory functions. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/pa/xm-pahpux.h
--- config/pa/xm-pahpux.h 1999/12/28 16:36:09 1.3
+++ config/pa/xm-pahpux.h 2001/02/28 05:59:26
@@ -19,14 +19,8 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
/* HP-UX is a flavor of System V */
#define USG
-
-/* Use System V memory functions. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
===================================================================
Index: config/pa/xm-papro.h
--- config/pa/xm-papro.h 2001/02/28 02:53:45 1.5
+++ config/pa/xm-papro.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/pj/xm-pj.h
--- config/pj/xm-pj.h 2000/01/05 05:57:17 1.1
+++ config/pj/xm-pj.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/romp/xm-romp.h
--- config/romp/xm-romp.h 2000/04/18 22:34:11 1.3
+++ config/romp/xm-romp.h 2001/02/28 05:59:26
@@ -18,11 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/rs6000/xm-beos.h
--- config/rs6000/xm-beos.h 2001/02/25 05:23:38 1.6
+++ config/rs6000/xm-beos.h 2001/02/28 05:59:26
@@ -21,12 +21,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
@@ -81,4 +75,3 @@ extern void *alloca ();
/* SYSTEM_INCLUDE_DIR is the location for system specific, non-POSIX headers. */
#define SYSTEM_INCLUDE_DIR "/boot/develop/headers/be"
-
===================================================================
Index: config/rs6000/xm-rs6000.h
--- config/rs6000/xm-rs6000.h 1998/12/16 21:12:50 1.6
+++ config/rs6000/xm-rs6000.h 2001/02/28 05:59:26
@@ -19,11 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/rs6000/xm-sysv4.h
--- config/rs6000/xm-sysv4.h 1999/09/07 05:49:01 1.10
+++ config/rs6000/xm-sysv4.h 2001/02/28 05:59:26
@@ -19,11 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/sh/xm-sh.h
--- config/sh/xm-sh.h 1998/12/16 21:13:02 1.2
+++ config/sh/xm-sh.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/sparc/xm-sparc.h
--- config/sparc/xm-sparc.h 1998/12/16 21:14:01 1.2
+++ config/sparc/xm-sparc.h 2001/02/28 05:59:26
@@ -19,11 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/sparc/xm-sysv4.h
--- config/sparc/xm-sysv4.h 1998/12/16 21:14:03 1.2
+++ config/sparc/xm-sysv4.h 2001/02/28 05:59:26
@@ -19,11 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/v850/xm-v850.h
--- config/v850/xm-v850.h 1999/09/07 05:49:10 1.5
+++ config/v850/xm-v850.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: config/vax/xm-vax.h
--- config/vax/xm-vax.h 1999/01/11 13:34:12 1.3
+++ config/vax/xm-vax.h 2001/02/28 05:59:26
@@ -18,10 +18,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* target machine dependencies.
tm.h is a symbolic link to the actual target specific file. */
#include "tm.h"
@@ -42,4 +38,3 @@ Boston, MA 02111-1307, USA. */
/* isinf isn't there, but finite is. */
#define isinf(x) (!finite(x))
-
===================================================================
Index: config/vax/xm-vms.h
--- config/vax/xm-vms.h 2001/02/25 05:23:38 1.8
+++ config/vax/xm-vms.h 2001/02/28 05:59:26
@@ -19,10 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* Other configurations get these via autoconfig. */
#define STDC_HEADERS 1
#define HAVE_STDLIB_H 1
===================================================================
Index: config/we32k/xm-we32k.h
--- config/we32k/xm-we32k.h 1999/12/28 16:36:09 1.3
+++ config/we32k/xm-we32k.h 2001/02/28 05:59:26
@@ -19,11 +19,6 @@ along with GNU CC; see the file COPYING.
the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-
-/* #defines that need visibility everywhere. */
-#define FALSE 0
-#define TRUE 1
-
/* This describes the machine the compiler is hosted on. */
#define HOST_BITS_PER_CHAR 8
#define HOST_BITS_PER_SHORT 16
===================================================================
Index: configure.in
--- configure.in 2001/02/16 11:12:45 1.486
+++ configure.in 2001/02/28 05:59:19
@@ -426,7 +426,7 @@ AC_HEADER_SYS_WAIT
AC_CHECK_HEADERS(limits.h stddef.h string.h strings.h stdlib.h time.h \
fcntl.h unistd.h stab.h sys/file.h sys/time.h \
sys/resource.h sys/param.h sys/times.h sys/stat.h \
- direct.h malloc.h langinfo.h iconv.h)
+ direct.h malloc.h langinfo.h iconv.h stdbool.h)
# Check for thread headers.
AC_CHECK_HEADER(thread.h, [have_thread_h=yes], [have_thread_h=])
===================================================================
Index: system.h
--- system.h 2000/12/22 12:27:36 1.86
+++ system.h 2001/02/28 05:59:25
@@ -43,6 +43,10 @@ Boston, MA 02111-1307, USA. */
# endif
#endif
+#ifdef HAVE_STDDEF_H
+# include <stddef.h>
+#endif
+
#include <stdio.h>
/* Define a generic NULL if one hasn't already been defined. */
@@ -355,6 +359,14 @@ extern void abort PARAMS ((void));
((GCC_VERSION >= 2007) || (__STDC_VERSION__ >= 199901L))
#endif
+/* 1 if we have _Bool. */
+#ifndef HAVE__BOOL
+# define HAVE__BOOL \
+ ((GCC_VERSION >= 3000) || (__STDC_VERSION__ >= 199901L))
+#endif
+
+
+
/* Define a STRINGIFY macro that's right for ANSI or traditional C.
Note: if the argument passed to STRINGIFY is itself a macro, eg
#define foo bar, STRINGIFY(foo) will produce "foo", not "bar".
@@ -532,5 +544,28 @@ extern void *alloca (__SIZE_TYPE__);
#define __FUNCTION__ "?"
#endif /* ! __FUNCTION__ */
#endif
+
+/* Provide some sort of boolean type. We use stdbool.h if it's
+ available. This is dead last because various system headers might
+ mess us up. */
+#undef bool
+#undef true
+#undef false
+#undef TRUE
+#undef FALSE
+
+#ifdef HAVE_STDBOOL_H
+# include <stdbool.h>
+#else
+# if !HAVE__BOOL
+typedef char _Bool;
+# endif
+# define bool _Bool
+# define true 1
+# define false 0
+#endif
+
+#define TRUE true
+#define FALSE false
#endif /* __GCC_SYSTEM_H__ */
===================================================================
Index: config.gcc
--- config.gcc 2001/02/26 18:15:36 1.32
+++ config.gcc 2001/02/28 05:59:18
@@ -971,7 +971,7 @@ i[34567]86-ibm-aix*) # IBM PS/2 running
tm_file=i386/aix386ng.h
use_collect2=yes
fi
- xm_file="xm-alloca.h i386/xm-aix.h ${xm_file}"
+ xm_file="xm-alloca.h ${xm_file}"
xm_defines=USG
xmake_file=i386/x-aix
;;
@@ -1220,7 +1220,6 @@ i[34567]86-*-osfrose*) # 386 using OSF/
tm_file=i386/osfrose.h
use_collect2=yes
fi
- xm_file="i386/xm-osf.h ${xm_file}"
xmake_file=i386/x-osfrose
tmake_file=i386/t-osf
extra_objs=halfpic.o
===================================================================
Index: combine.c
--- combine.c 2001/02/27 00:48:10 1.186
+++ combine.c 2001/02/28 05:59:17
@@ -3609,15 +3609,15 @@ combine_simplify_rtx (x, op0_mode, last,
&& (GET_RTX_CLASS (GET_CODE (SUBREG_REG (XEXP (x, 0))))
== 'o'))))))
{
- rtx cond, true, false;
+ rtx cond, true_rtx, false_rtx;
- cond = if_then_else_cond (x, &true, &false);
+ cond = if_then_else_cond (x, &true_rtx, &false_rtx);
if (cond != 0
/* If everything is a comparison, what we have is highly unlikely
to be simpler, so don't use it. */
&& ! (GET_RTX_CLASS (code) == '<'
- && (GET_RTX_CLASS (GET_CODE (true)) == '<'
- || GET_RTX_CLASS (GET_CODE (false)) == '<')))
+ && (GET_RTX_CLASS (GET_CODE (true_rtx)) == '<'
+ || GET_RTX_CLASS (GET_CODE (false_rtx)) == '<')))
{
rtx cop1 = const0_rtx;
enum rtx_code cond_code = simplify_comparison (NE, &cond, &cop1);
@@ -3627,35 +3627,35 @@ combine_simplify_rtx (x, op0_mode, last,
/* Simplify the alternative arms; this may collapse the true and
false arms to store-flag values. */
- true = subst (true, pc_rtx, pc_rtx, 0, 0);
- false = subst (false, pc_rtx, pc_rtx, 0, 0);
+ true_rtx = subst (true_rtx, pc_rtx, pc_rtx, 0, 0);
+ false_rtx = subst (false_rtx, pc_rtx, pc_rtx, 0, 0);
- /* If true and false are not general_operands, an if_then_else
+ /* If true_rtx and false_rtx are not general_operands, an if_then_else
is unlikely to be simpler. */
- if (general_operand (true, VOIDmode)
- && general_operand (false, VOIDmode))
+ if (general_operand (true_rtx, VOIDmode)
+ && general_operand (false_rtx, VOIDmode))
{
/* Restarting if we generate a store-flag expression will cause
us to loop. Just drop through in this case. */
/* If the result values are STORE_FLAG_VALUE and zero, we can
just make the comparison operation. */
- if (true == const_true_rtx && false == const0_rtx)
+ if (true_rtx == const_true_rtx && false_rtx == const0_rtx)
x = gen_binary (cond_code, mode, cond, cop1);
- else if (true == const0_rtx && false == const_true_rtx)
+ else if (true_rtx == const0_rtx && false_rtx == const_true_rtx)
x = gen_binary (reverse_condition (cond_code),
mode, cond, cop1);
/* Likewise, we can make the negate of a comparison operation
if the result values are - STORE_FLAG_VALUE and zero. */
- else if (GET_CODE (true) == CONST_INT
- && INTVAL (true) == - STORE_FLAG_VALUE
- && false == const0_rtx)
+ else if (GET_CODE (true_rtx) == CONST_INT
+ && INTVAL (true_rtx) == - STORE_FLAG_VALUE
+ && false_rtx == const0_rtx)
x = gen_unary (NEG, mode, mode,
gen_binary (cond_code, mode, cond, cop1));
- else if (GET_CODE (false) == CONST_INT
- && INTVAL (false) == - STORE_FLAG_VALUE
- && true == const0_rtx)
+ else if (GET_CODE (false_rtx) == CONST_INT
+ && INTVAL (false_rtx) == - STORE_FLAG_VALUE
+ && true_rtx == const0_rtx)
x = gen_unary (NEG, mode, mode,
gen_binary (reverse_condition (cond_code),
mode, cond, cop1));
@@ -3663,7 +3663,7 @@ combine_simplify_rtx (x, op0_mode, last,
return gen_rtx_IF_THEN_ELSE (mode,
gen_binary (cond_code, VOIDmode,
cond, cop1),
- true, false);
+ true_rtx, false_rtx);
code = GET_CODE (x);
op0_mode = VOIDmode;
@@ -4649,8 +4649,8 @@ simplify_if_then_else (x)
{
enum machine_mode mode = GET_MODE (x);
rtx cond = XEXP (x, 0);
- rtx true = XEXP (x, 1);
- rtx false = XEXP (x, 2);
+ rtx true_rtx = XEXP (x, 1);
+ rtx false_rtx = XEXP (x, 2);
enum rtx_code true_code = GET_CODE (cond);
int comparison_p = GET_RTX_CLASS (true_code) == '<';
rtx temp;
@@ -4659,12 +4659,12 @@ simplify_if_then_else (x)
rtx reversed;
/* Simplify storing of the truth value. */
- if (comparison_p && true == const_true_rtx && false == const0_rtx)
+ if (comparison_p && true_rtx == const_true_rtx && false_rtx == const0_rtx)
return gen_binary (true_code, mode, XEXP (cond, 0), XEXP (cond, 1));
/* Also when the truth value has to be reversed. */
if (comparison_p
- && true == const0_rtx && false == const_true_rtx
+ && true_rtx == const0_rtx && false_rtx == const_true_rtx
&& (reversed = reversed_comparison (cond, mode, XEXP (cond, 0),
XEXP (cond, 1))))
return reversed;
@@ -4689,7 +4689,7 @@ simplify_if_then_else (x)
if (false_code == EQ)
{
swapped = 1, true_code = EQ, false_code = NE;
- temp = true, true = false, false = temp;
+ temp = true_rtx, true_rtx = false_rtx, false_rtx = temp;
}
/* If we are comparing against zero and the expression being tested has
@@ -4708,18 +4708,21 @@ simplify_if_then_else (x)
branch and it is used in the arm. Be careful due to the potential
of locally-shared RTL. */
- if (reg_mentioned_p (from, true))
- true = subst (known_cond (copy_rtx (true), true_code, from, true_val),
+ if (reg_mentioned_p (from, true_rtx))
+ true_rtx = subst (known_cond (copy_rtx (true_rtx), true_code,
+ from, true_val),
pc_rtx, pc_rtx, 0, 0);
- if (reg_mentioned_p (from, false))
- false = subst (known_cond (copy_rtx (false), false_code,
+ if (reg_mentioned_p (from, false_rtx))
+ false_rtx = subst (known_cond (copy_rtx (false_rtx), false_code,
from, false_val),
pc_rtx, pc_rtx, 0, 0);
- SUBST (XEXP (x, 1), swapped ? false : true);
- SUBST (XEXP (x, 2), swapped ? true : false);
+ SUBST (XEXP (x, 1), swapped ? false_rtx : true_rtx);
+ SUBST (XEXP (x, 2), swapped ? true_rtx : false_rtx);
- true = XEXP (x, 1), false = XEXP (x, 2), true_code = GET_CODE (cond);
+ true_rtx = XEXP (x, 1);
+ false_rtx = XEXP (x, 2);
+ true_code = GET_CODE (cond);
}
/* If we have (if_then_else FOO (pc) (label_ref BAR)) and FOO can be
@@ -4730,27 +4733,28 @@ simplify_if_then_else (x)
if (comparison_p
&& combine_reversed_comparison_code (cond) != UNKNOWN
- && (true == pc_rtx
- || (CONSTANT_P (true)
- && GET_CODE (false) != CONST_INT && false != pc_rtx)
- || true == const0_rtx
- || (GET_RTX_CLASS (GET_CODE (true)) == 'o'
- && GET_RTX_CLASS (GET_CODE (false)) != 'o')
- || (GET_CODE (true) == SUBREG
- && GET_RTX_CLASS (GET_CODE (SUBREG_REG (true))) == 'o'
- && GET_RTX_CLASS (GET_CODE (false)) != 'o')
- || reg_mentioned_p (true, false)
- || rtx_equal_p (false, XEXP (cond, 0))))
+ && (true_rtx == pc_rtx
+ || (CONSTANT_P (true_rtx)
+ && GET_CODE (false_rtx) != CONST_INT && false_rtx != pc_rtx)
+ || true_rtx == const0_rtx
+ || (GET_RTX_CLASS (GET_CODE (true_rtx)) == 'o'
+ && GET_RTX_CLASS (GET_CODE (false_rtx)) != 'o')
+ || (GET_CODE (true_rtx) == SUBREG
+ && GET_RTX_CLASS (GET_CODE (SUBREG_REG (true_rtx))) == 'o'
+ && GET_RTX_CLASS (GET_CODE (false_rtx)) != 'o')
+ || reg_mentioned_p (true_rtx, false_rtx)
+ || rtx_equal_p (false_rtx, XEXP (cond, 0))))
{
true_code = reversed_comparison_code (cond, NULL);
SUBST (XEXP (x, 0),
reversed_comparison (cond, GET_MODE (cond), XEXP (cond, 0),
XEXP (cond, 1)));
- SUBST (XEXP (x, 1), false);
- SUBST (XEXP (x, 2), true);
+ SUBST (XEXP (x, 1), false_rtx);
+ SUBST (XEXP (x, 2), true_rtx);
- temp = true, true = false, false = temp, cond = XEXP (x, 0);
+ temp = true_rtx, true_rtx = false_rtx, false_rtx = temp;
+ cond = XEXP (x, 0);
/* It is possible that the conditional has been simplified out. */
true_code = GET_CODE (cond);
@@ -4759,37 +4763,38 @@ simplify_if_then_else (x)
/* If the two arms are identical, we don't need the comparison. */
- if (rtx_equal_p (true, false) && ! side_effects_p (cond))
- return true;
+ if (rtx_equal_p (true_rtx, false_rtx) && ! side_effects_p (cond))
+ return true_rtx;
/* Convert a == b ? b : a to "a". */
if (true_code == EQ && ! side_effects_p (cond)
&& (! FLOAT_MODE_P (mode) || flag_fast_math)
- && rtx_equal_p (XEXP (cond, 0), false)
- && rtx_equal_p (XEXP (cond, 1), true))
- return false;
+ && rtx_equal_p (XEXP (cond, 0), false_rtx)
+ && rtx_equal_p (XEXP (cond, 1), true_rtx))
+ return false_rtx;
else if (true_code == NE && ! side_effects_p (cond)
&& (! FLOAT_MODE_P (mode) || flag_fast_math)
- && rtx_equal_p (XEXP (cond, 0), true)
- && rtx_equal_p (XEXP (cond, 1), false))
- return true;
+ && rtx_equal_p (XEXP (cond, 0), true_rtx)
+ && rtx_equal_p (XEXP (cond, 1), false_rtx))
+ return true_rtx;
/* Look for cases where we have (abs x) or (neg (abs X)). */
if (GET_MODE_CLASS (mode) == MODE_INT
- && GET_CODE (false) == NEG
- && rtx_equal_p (true, XEXP (false, 0))
+ && GET_CODE (false_rtx) == NEG
+ && rtx_equal_p (true_rtx, XEXP (false_rtx, 0))
&& comparison_p
- && rtx_equal_p (true, XEXP (cond, 0))
- && ! side_effects_p (true))
+ && rtx_equal_p (true_rtx, XEXP (cond, 0))
+ && ! side_effects_p (true_rtx))
switch (true_code)
{
case GT:
case GE:
- return gen_unary (ABS, mode, mode, true);
+ return gen_unary (ABS, mode, mode, true_rtx);
case LT:
case LE:
- return gen_unary (NEG, mode, mode, gen_unary (ABS, mode, mode, true));
+ return gen_unary (NEG, mode, mode,
+ gen_unary (ABS, mode, mode, true_rtx));
default:
break;
}
@@ -4798,23 +4803,23 @@ simplify_if_then_else (x)
if ((! FLOAT_MODE_P (mode) || flag_fast_math)
&& comparison_p
- && rtx_equal_p (XEXP (cond, 0), true)
- && rtx_equal_p (XEXP (cond, 1), false)
+ && rtx_equal_p (XEXP (cond, 0), true_rtx)
+ && rtx_equal_p (XEXP (cond, 1), false_rtx)
&& ! side_effects_p (cond))
switch (true_code)
{
case GE:
case GT:
- return gen_binary (SMAX, mode, true, false);
+ return gen_binary (SMAX, mode, true_rtx, false_rtx);
case LE:
case LT:
- return gen_binary (SMIN, mode, true, false);
+ return gen_binary (SMIN, mode, true_rtx, false_rtx);
case GEU:
case GTU:
- return gen_binary (UMAX, mode, true, false);
+ return gen_binary (UMAX, mode, true_rtx, false_rtx);
case LEU:
case LTU:
- return gen_binary (UMIN, mode, true, false);
+ return gen_binary (UMIN, mode, true_rtx, false_rtx);
default:
break;
}
@@ -4829,8 +4834,8 @@ simplify_if_then_else (x)
if ((STORE_FLAG_VALUE == 1 || STORE_FLAG_VALUE == -1)
&& comparison_p && mode != VOIDmode && ! side_effects_p (x))
{
- rtx t = make_compound_operation (true, SET);
- rtx f = make_compound_operation (false, SET);
+ rtx t = make_compound_operation (true_rtx, SET);
+ rtx f = make_compound_operation (false_rtx, SET);
rtx cond_op0 = XEXP (cond, 0);
rtx cond_op1 = XEXP (cond, 1);
enum rtx_code op = NIL, extend_op = NIL;
@@ -4943,12 +4948,12 @@ simplify_if_then_else (x)
can actually do this more generally, but it doesn't seem worth it. */
if (true_code == NE && XEXP (cond, 1) == const0_rtx
- && false == const0_rtx && GET_CODE (true) == CONST_INT
+ && false_rtx == const0_rtx && GET_CODE (true_rtx) == CONST_INT
&& ((1 == nonzero_bits (XEXP (cond, 0), mode)
- && (i = exact_log2 (INTVAL (true))) >= 0)
+ && (i = exact_log2 (INTVAL (true_rtx))) >= 0)
|| ((num_sign_bit_copies (XEXP (cond, 0), mode)
== GET_MODE_BITSIZE (mode))
- && (i = exact_log2 (-INTVAL (true))) >= 0)))
+ && (i = exact_log2 (-INTVAL (true_rtx))) >= 0)))
return
simplify_shift_const (NULL_RTX, ASHIFT, mode,
gen_lowpart_for_combine (mode, XEXP (cond, 0)), i);
@@ -5197,29 +5202,31 @@ simplify_set (x)
== GET_MODE_BITSIZE (GET_MODE (XEXP (XEXP (src, 0), 0))))
&& ! side_effects_p (src))
{
- rtx true = (GET_CODE (XEXP (src, 0)) == NE
+ rtx true_rtx = (GET_CODE (XEXP (src, 0)) == NE
? XEXP (src, 1) : XEXP (src, 2));
- rtx false = (GET_CODE (XEXP (src, 0)) == NE
+ rtx false_rtx = (GET_CODE (XEXP (src, 0)) == NE
? XEXP (src, 2) : XEXP (src, 1));
rtx term1 = const0_rtx, term2, term3;
- if (GET_CODE (true) == IOR && rtx_equal_p (XEXP (true, 0), false))
- term1 = false, true = XEXP (true, 1), false = const0_rtx;
- else if (GET_CODE (true) == IOR
- && rtx_equal_p (XEXP (true, 1), false))
- term1 = false, true = XEXP (true, 0), false = const0_rtx;
- else if (GET_CODE (false) == IOR
- && rtx_equal_p (XEXP (false, 0), true))
- term1 = true, false = XEXP (false, 1), true = const0_rtx;
- else if (GET_CODE (false) == IOR
- && rtx_equal_p (XEXP (false, 1), true))
- term1 = true, false = XEXP (false, 0), true = const0_rtx;
+ if (GET_CODE (true_rtx) == IOR
+ && rtx_equal_p (XEXP (true_rtx, 0), false_rtx))
+ term1 = false_rtx, true_rtx = XEXP(true_rtx, 1), false_rtx = const0_rtx;
+ else if (GET_CODE (true_rtx) == IOR
+ && rtx_equal_p (XEXP (true_rtx, 1), false_rtx))
+ term1 = false_rtx, true_rtx = XEXP(true_rtx, 0), false_rtx = const0_rtx;
+ else if (GET_CODE (false_rtx) == IOR
+ && rtx_equal_p (XEXP (false_rtx, 0), true_rtx))
+ term1 = true_rtx, false_rtx = XEXP(false_rtx, 1), true_rtx = const0_rtx;
+ else if (GET_CODE (false_rtx) == IOR
+ && rtx_equal_p (XEXP (false_rtx, 1), true_rtx))
+ term1 = true_rtx, false_rtx = XEXP(false_rtx, 0), true_rtx = const0_rtx;
- term2 = gen_binary (AND, GET_MODE (src), XEXP (XEXP (src, 0), 0), true);
+ term2 = gen_binary (AND, GET_MODE (src),
+ XEXP (XEXP (src, 0), 0), true_rtx);
term3 = gen_binary (AND, GET_MODE (src),
gen_unary (NOT, GET_MODE (src), GET_MODE (src),
XEXP (XEXP (src, 0), 0)),
- false);
+ false_rtx);
SUBST (SET_SRC (x),
gen_binary (IOR, GET_MODE (src),
===================================================================
Index: cse.c
--- cse.c 2001/02/16 17:50:49 1.176
+++ cse.c 2001/02/28 05:59:21
@@ -3913,15 +3913,15 @@ fold_rtx (x, insn)
if (const_arg0 == 0 || const_arg1 == 0)
{
struct table_elt *p0, *p1;
- rtx true = const_true_rtx, false = const0_rtx;
+ rtx true_rtx = const_true_rtx, false_rtx = const0_rtx;
enum machine_mode mode_arg1;
#ifdef FLOAT_STORE_FLAG_VALUE
if (GET_MODE_CLASS (mode) == MODE_FLOAT)
{
- true = (CONST_DOUBLE_FROM_REAL_VALUE
+ true_rtx = (CONST_DOUBLE_FROM_REAL_VALUE
(FLOAT_STORE_FLAG_VALUE (mode), mode));
- false = CONST0_RTX (mode);
+ false_rtx = CONST0_RTX (mode);
}
#endif
@@ -3955,9 +3955,9 @@ fold_rtx (x, insn)
|| GET_CODE (folded_arg0) == CONST))
{
if (code == EQ)
- return false;
+ return false_rtx;
else if (code == NE)
- return true;
+ return true_rtx;
}
/* See if the two operands are the same. */
@@ -3981,12 +3981,12 @@ fold_rtx (x, insn)
return ((code == EQ || code == LE || code == GE
|| code == LEU || code == GEU || code == UNEQ
|| code == UNLE || code == UNGE || code == ORDERED)
- ? true : false);
+ ? true_rtx : false_rtx);
/* Take care for the FP compares we can resolve. */
if (code == UNEQ || code == UNLE || code == UNGE)
- return true;
+ return true_rtx;
if (code == LTGT || code == LT || code == GT)
- return false;
+ return false_rtx;
}
/* If FOLDED_ARG0 is a register, see if the comparison we are
@@ -4011,7 +4011,7 @@ fold_rtx (x, insn)
|| (GET_CODE (folded_arg1) == REG
&& (REG_QTY (REGNO (folded_arg1)) == ent->comparison_qty))))
return (comparison_dominates_p (ent->comparison_code, code)
- ? true : false);
+ ? true_rtx : false_rtx);
}
}
}
@@ -4035,30 +4035,30 @@ fold_rtx (x, insn)
int has_sign = (HOST_BITS_PER_WIDE_INT >= sign_bitnum
&& (INTVAL (inner_const)
& ((HOST_WIDE_INT) 1 << sign_bitnum)));
- rtx true = const_true_rtx, false = const0_rtx;
+ rtx true_rtx = const_true_rtx, false_rtx = const0_rtx;
#ifdef FLOAT_STORE_FLAG_VALUE
if (GET_MODE_CLASS (mode) == MODE_FLOAT)
{
- true = (CONST_DOUBLE_FROM_REAL_VALUE
+ true_rtx = (CONST_DOUBLE_FROM_REAL_VALUE
(FLOAT_STORE_FLAG_VALUE (mode), mode));
- false = CONST0_RTX (mode);
+ false_rtx = CONST0_RTX (mode);
}
#endif
switch (code)
{
case EQ:
- return false;
+ return false_rtx;
case NE:
- return true;
+ return true_rtx;
case LT: case LE:
if (has_sign)
- return true;
+ return true_rtx;
break;
case GT: case GE:
if (has_sign)
- return false;
+ return false_rtx;
break;
default:
break;
===================================================================
Index: expr.c
--- expr.c 2001/02/04 22:43:59 1.295
+++ expr.c 2001/02/28 05:59:22
@@ -7956,21 +7956,21 @@ expand_expr (exp, target, tmode, modifie
&& (TREE_TYPE (TREE_OPERAND (TREE_OPERAND (exp, 1), 0))
== TREE_TYPE (TREE_OPERAND (TREE_OPERAND (exp, 2), 0))))
{
- tree true = TREE_OPERAND (TREE_OPERAND (exp, 1), 0);
- tree false = TREE_OPERAND (TREE_OPERAND (exp, 2), 0);
+ tree iftrue = TREE_OPERAND (TREE_OPERAND (exp, 1), 0);
+ tree iffalse = TREE_OPERAND (TREE_OPERAND (exp, 2), 0);
- if ((TREE_CODE_CLASS (TREE_CODE (true)) == '2'
- && operand_equal_p (false, TREE_OPERAND (true, 0), 0))
- || (TREE_CODE_CLASS (TREE_CODE (false)) == '2'
- && operand_equal_p (true, TREE_OPERAND (false, 0), 0))
- || (TREE_CODE_CLASS (TREE_CODE (true)) == '1'
- && operand_equal_p (false, TREE_OPERAND (true, 0), 0))
- || (TREE_CODE_CLASS (TREE_CODE (false)) == '1'
- && operand_equal_p (true, TREE_OPERAND (false, 0), 0)))
+ if ((TREE_CODE_CLASS (TREE_CODE (iftrue)) == '2'
+ && operand_equal_p (iffalse, TREE_OPERAND (iftrue, 0), 0))
+ || (TREE_CODE_CLASS (TREE_CODE (iffalse)) == '2'
+ && operand_equal_p (iftrue, TREE_OPERAND (iffalse, 0), 0))
+ || (TREE_CODE_CLASS (TREE_CODE (iftrue)) == '1'
+ && operand_equal_p (iffalse, TREE_OPERAND (iftrue, 0), 0))
+ || (TREE_CODE_CLASS (TREE_CODE (iffalse)) == '1'
+ && operand_equal_p (iftrue, TREE_OPERAND (iffalse, 0), 0)))
return expand_expr (build1 (NOP_EXPR, type,
- build (COND_EXPR, TREE_TYPE (true),
+ build (COND_EXPR, TREE_TYPE (iftrue),
TREE_OPERAND (exp, 0),
- true, false)),
+ iftrue, iffalse)),
target, tmode, modifier);
}
===================================================================
Index: fold-const.c
--- fold-const.c 2001/02/23 21:05:41 1.150
+++ fold-const.c 2001/02/28 05:59:23
@@ -4695,16 +4695,16 @@ count_cond (expr, lim)
tree expr;
int lim;
{
- int true, false;
+ int ctrue, cfalse;
if (TREE_CODE (expr) != COND_EXPR)
return 0;
else if (lim <= 0)
return 0;
- true = count_cond (TREE_OPERAND (expr, 1), lim - 1);
- false = count_cond (TREE_OPERAND (expr, 2), lim - 1 - true);
- return MIN (lim, 1 + true + false);
+ ctrue = count_cond (TREE_OPERAND (expr, 1), lim - 1);
+ cfalse = count_cond (TREE_OPERAND (expr, 2), lim - 1 - true);
+ return MIN (lim, 1 + ctrue + cfalse);
}
/* Transform `a + (b ? x : y)' into `x ? (a + b) : (a + y)'.
===================================================================
Index: function.c
--- function.c 2001/02/24 13:15:55 1.253
+++ function.c 2001/02/28 05:59:24
@@ -294,7 +294,7 @@ static int contains PARAMS ((rtx, varra
static void emit_return_into_block PARAMS ((basic_block, rtx));
#endif
static void put_addressof_into_stack PARAMS ((rtx, struct hash_table *));
-static boolean purge_addressof_1 PARAMS ((rtx *, rtx, int, int,
+static bool purge_addressof_1 PARAMS ((rtx *, rtx, int, int,
struct hash_table *));
static void purge_single_hard_subreg_set PARAMS ((rtx));
#ifdef HAVE_epilogue
@@ -305,7 +305,7 @@ static struct hash_entry *insns_for_mem_
struct hash_table *,
hash_table_key));
static unsigned long insns_for_mem_hash PARAMS ((hash_table_key));
-static boolean insns_for_mem_comp PARAMS ((hash_table_key, hash_table_key));
+static bool insns_for_mem_comp PARAMS ((hash_table_key, hash_table_key));
static int insns_for_mem_walk PARAMS ((rtx *, void *));
static void compute_insns_for_mem PARAMS ((rtx, rtx, struct hash_table *));
static void mark_temp_slot PARAMS ((struct temp_slot *));
@@ -2969,7 +2969,7 @@ static rtx purge_addressof_replacements;
the stack. If the function returns FALSE then the replacement could not
be made. */
-static boolean
+static bool
purge_addressof_1 (loc, insn, force, store, ht)
rtx *loc;
rtx insn;
@@ -2980,7 +2980,7 @@ purge_addressof_1 (loc, insn, force, sto
RTX_CODE code;
int i, j;
const char *fmt;
- boolean result = true;
+ bool result = true;
/* Re-start here to avoid recursion in common cases. */
restart:
@@ -3280,7 +3280,7 @@ insns_for_mem_hash (k)
/* Return non-zero if K1 and K2 (two REGs) are the same. */
-static boolean
+static bool
insns_for_mem_comp (k1, k2)
hash_table_key k1;
hash_table_key k2;
===================================================================
Index: gensupport.c
--- gensupport.c 2000/11/22 01:22:01 1.12
+++ gensupport.c 2001/02/28 05:59:25
@@ -321,7 +321,7 @@ static void
identify_predicable_attribute ()
{
struct queue_elem *elem;
- char *true, *false;
+ char *p_true, *p_false;
const char *value;
size_t len;
@@ -338,21 +338,21 @@ identify_predicable_attribute ()
found:
value = XSTR (elem->data, 1);
len = strlen (value);
- false = (char *) xmalloc (len + 1);
- memcpy (false, value, len + 1);
+ p_false = (char *) xmalloc (len + 1);
+ memcpy (p_false, value, len + 1);
- true = strchr (false, ',');
- if (true == NULL || strchr (++true, ',') != NULL)
+ p_true = strchr (p_false, ',');
+ if (p_true == NULL || strchr (++p_true, ',') != NULL)
{
message_with_line (elem->lineno,
"Attribute `predicable' is not a boolean");
errors = 1;
return;
}
- true[-1] = '\0';
+ p_true[-1] = '\0';
- predicable_true = true;
- predicable_false = false;
+ predicable_true = p_true;
+ predicable_false = p_false;
switch (GET_CODE (XEXP (elem->data, 2)))
{
@@ -373,9 +373,9 @@ identify_predicable_attribute ()
return;
}
- if (strcmp (value, true) == 0)
+ if (strcmp (value, p_true) == 0)
predicable_default = 1;
- else if (strcmp (value, false) == 0)
+ else if (strcmp (value, p_false) == 0)
predicable_default = 0;
else
{
===================================================================
Index: ggc-common.c
--- ggc-common.c 2001/02/20 05:49:05 1.35
+++ ggc-common.c 2001/02/28 05:59:25
@@ -48,7 +48,7 @@ static void ggc_mark_rtx_varray_ptr PARA
static void ggc_mark_tree_varray_ptr PARAMS ((void *));
static void ggc_mark_tree_hash_table_ptr PARAMS ((void *));
static void ggc_mark_trees PARAMS ((void));
-static boolean ggc_mark_tree_hash_table_entry PARAMS ((struct hash_entry *,
+static bool ggc_mark_tree_hash_table_entry PARAMS ((struct hash_entry *,
hash_table_key));
/* Maintain global roots that are preserved during GC. */
@@ -462,7 +462,7 @@ ggc_mark_tree_varray (v)
/* Mark the hash table-entry HE. It's key field is really a tree. */
-static boolean
+static bool
ggc_mark_tree_hash_table_entry (he, k)
struct hash_entry *he;
hash_table_key k ATTRIBUTE_UNUSED;
===================================================================
Index: hash.c
--- hash.c 2001/02/04 22:44:00 1.14
+++ hash.c 2001/02/28 05:59:25
@@ -41,7 +41,7 @@ hash_table_init_n (table, newfunc, hash,
struct hash_table *,
hash_table_key));
unsigned long (*hash) PARAMS ((hash_table_key));
- boolean (*comp) PARAMS ((hash_table_key, hash_table_key));
+ bool (*comp) PARAMS ((hash_table_key, hash_table_key));
unsigned int size;
{
unsigned int alloc;
@@ -66,7 +66,7 @@ hash_table_init (table, newfunc, hash, c
struct hash_table *,
hash_table_key));
unsigned long (*hash) PARAMS ((hash_table_key));
- boolean (*comp) PARAMS ((hash_table_key, hash_table_key));
+ bool (*comp) PARAMS ((hash_table_key, hash_table_key));
{
hash_table_init_n (table, newfunc, hash, comp, DEFAULT_SIZE);
}
@@ -87,7 +87,7 @@ struct hash_entry *
hash_lookup (table, key, create, copy)
struct hash_table *table;
hash_table_key key;
- boolean create;
+ bool create;
hash_table_key (*copy) PARAMS ((struct obstack* memory,
hash_table_key key));
{
@@ -150,7 +150,7 @@ hash_allocate (table, size)
void
hash_traverse (table, func, info)
struct hash_table *table;
- boolean (*func) PARAMS ((struct hash_entry *, hash_table_key));
+ bool (*func) PARAMS ((struct hash_entry *, hash_table_key));
PTR info;
{
unsigned int i;
@@ -193,7 +193,7 @@ string_hash (k)
/* Compare two strings. Return non-zero iff the two strings are
the same. */
-boolean
+bool
string_compare (k1, k2)
hash_table_key k1;
hash_table_key k2;
===================================================================
Index: hash.h
--- hash.h 2001/02/04 22:44:00 1.10
+++ hash.h 2001/02/28 05:59:25
@@ -25,12 +25,6 @@ Boston, MA 02111-1307, USA. */
#include "obstack.h"
-#undef false
-#undef true
-#undef boolean
-
-typedef enum {false, true} boolean;
-
typedef PTR hash_table_key;
/* Hash table routines. There is no way to free up a hash table. */
@@ -70,7 +64,7 @@ struct hash_table
/* A function to compute the hash code for a key in the hash table. */
unsigned long (*hash) PARAMS ((hash_table_key));
/* A function to compare two keys. */
- boolean (*comp) PARAMS ((hash_table_key, hash_table_key));
+ bool (*comp) PARAMS ((hash_table_key, hash_table_key));
/* An obstack for this hash table. */
struct obstack memory;
};
@@ -82,7 +76,7 @@ extern void hash_table_init
struct hash_table *,
hash_table_key),
unsigned long (*hash) (hash_table_key),
- boolean (*comp) (hash_table_key, hash_table_key)));
+ bool (*comp) (hash_table_key, hash_table_key)));
/* Initialize a hash table specifying a size. */
extern void hash_table_init_n
@@ -91,7 +85,7 @@ extern void hash_table_init_n
struct hash_table *,
hash_table_key),
unsigned long (*hash) (hash_table_key),
- boolean (*comp) (hash_table_key, hash_table_key),
+ bool (*comp) (hash_table_key, hash_table_key),
unsigned int size));
/* Free up a hash table. */
@@ -102,7 +96,7 @@ extern void hash_table_free PARAMS ((str
COPY is non-NULL, it is used to copy the KEY before storing it in
the hash table. */
extern struct hash_entry *hash_lookup
- PARAMS ((struct hash_table *, hash_table_key key, boolean create,
+ PARAMS ((struct hash_table *, hash_table_key key, bool create,
hash_table_key (*copy)(struct obstack*, hash_table_key)));
/* Base method for creating a hash table entry. */
@@ -118,7 +112,7 @@ extern PTR hash_allocate PARAMS ((struct
element. If the function returns false, the traversal stops. The
INFO argument is passed to the function. */
extern void hash_traverse PARAMS ((struct hash_table *,
- boolean (*) (struct hash_entry *,
+ bool (*) (struct hash_entry *,
hash_table_key),
hash_table_key info));
@@ -126,7 +120,7 @@ extern void hash_traverse PARAMS ((struc
extern unsigned long string_hash PARAMS ((hash_table_key k));
/* Compare two strings K1, K2 which are really of type `char*'. */
-extern boolean string_compare PARAMS ((hash_table_key k1,
+extern bool string_compare PARAMS ((hash_table_key k1,
hash_table_key k2));
/* Copy a string K, which is really of type `char*'. */
===================================================================
Index: tlink.c
--- tlink.c 2000/11/02 19:03:56 1.32
+++ tlink.c 2001/02/28 05:59:25
@@ -72,7 +72,7 @@ static struct hash_entry * symbol_hash_n
struct hash_table *,
hash_table_key));
static struct symbol_hash_entry * symbol_hash_lookup PARAMS ((const char *,
- boolean));
+ bool));
static struct hash_entry * file_hash_newfunc PARAMS ((struct hash_entry *,
struct hash_table *,
hash_table_key));
@@ -81,7 +81,7 @@ static struct hash_entry * demangled_has
struct hash_table *,
hash_table_key));
static struct demangled_hash_entry *
- demangled_hash_lookup PARAMS ((const char *, boolean));
+ demangled_hash_lookup PARAMS ((const char *, bool));
static void symbol_push PARAMS ((symbol *));
static symbol * symbol_pop PARAMS ((void));
static void file_push PARAMS ((file *));
@@ -129,7 +129,7 @@ symbol_hash_newfunc (entry, table, strin
static struct symbol_hash_entry *
symbol_hash_lookup (string, create)
const char *string;
- boolean create;
+ bool create;
{
return ((struct symbol_hash_entry *)
hash_lookup (&symbol_table, (const hash_table_key) string,
@@ -201,7 +201,7 @@ demangled_hash_newfunc (entry, table, st
static struct demangled_hash_entry *
demangled_hash_lookup (string, create)
const char *string;
- boolean create;
+ bool create;
{
return ((struct demangled_hash_entry *)
hash_lookup (&demangled_table, (const hash_table_key) string,
===================================================================
Index: cp/decl.c
--- cp/decl.c 2001/02/26 11:01:44 1.755
+++ cp/decl.c 2001/02/28 05:59:28
@@ -93,7 +93,7 @@ static void bad_specifiers PARAMS ((tree
static tree maybe_process_template_type_declaration PARAMS ((tree, int, struct binding_level*));
static void check_for_uninitialized_const_var PARAMS ((tree));
static unsigned long typename_hash PARAMS ((hash_table_key));
-static boolean typename_compare PARAMS ((hash_table_key, hash_table_key));
+static bool typename_compare PARAMS ((hash_table_key, hash_table_key));
static void push_binding PARAMS ((tree, tree, struct binding_level*));
static int add_binding PARAMS ((tree, tree));
static void pop_binding PARAMS ((tree, tree));
@@ -5495,7 +5495,7 @@ typename_hash (k)
/* Compare two TYPENAME_TYPEs. K1 and K2 are really of type `tree'. */
-static boolean
+static bool
typename_compare (k1, k2)
hash_table_key k1;
hash_table_key k2;
===================================================================
Index: f/com.c
--- f/com.c 2001/02/25 05:23:33 1.112
+++ f/com.c 2001/02/28 05:59:30
@@ -4515,21 +4515,21 @@ ffecom_expr_intrinsic_ (ffebld expr, tre
case FFEINTRIN_impBTEST:
{
- ffetargetLogical1 true;
- ffetargetLogical1 false;
+ ffetargetLogical1 target_true;
+ ffetargetLogical1 target_false;
tree true_tree;
tree false_tree;
- ffetarget_logical1 (&true, TRUE);
- ffetarget_logical1 (&false, FALSE);
- if (true == 1)
+ ffetarget_logical1 (&target_true, TRUE);
+ ffetarget_logical1 (&target_false, FALSE);
+ if (target_true == 1)
true_tree = convert (tree_type, integer_one_node);
else
- true_tree = convert (tree_type, build_int_2 (true, 0));
- if (false == 0)
+ true_tree = convert (tree_type, build_int_2 (target_true, 0));
+ if (target_false == 0)
false_tree = convert (tree_type, integer_zero_node);
else
- false_tree = convert (tree_type, build_int_2 (false, 0));
+ false_tree = convert (tree_type, build_int_2 (target_false, 0));
return
ffecom_3 (COND_EXPR, tree_type,
===================================================================
Index: f/proj.h
--- f/proj.h 2000/08/24 20:32:41 1.16
+++ f/proj.h 2001/02/28 06:10:01
@@ -35,28 +35,9 @@ the Free Software Foundation, 59 Temple
#error "You have to use gcc 2.x to build g77 (might be fixed in g77-0.6)."
#endif
-/* Include files everyone gets. <assert.h> is needed for assert().
- <stddef.h> is needed for offsetof, but technically also NULL,
- size_t, ptrdiff_t, and so on. */
+/* Include files everyone gets. <assert.h> is needed for assert(). */
#include "assert.h"
-
-#if HAVE_STDDEF_H
-#include <stddef.h>
-#endif
-
-/* Generally useful definitions. */
-
-typedef enum
- {
-#if !defined(false) || !defined(true)
- false = 0, true = 1,
-#endif
-#if !defined(FALSE) || !defined(TRUE)
- FALSE = 0, TRUE = 1,
-#endif
- Doggone_Trailing_Comma_Dont_Work = 1
- } bool;
#ifndef UNUSED /* Compile with -DUNUSED= if cc doesn't support this. */
#define UNUSED ATTRIBUTE_UNUSED
===================================================================
Index: java/class.c
--- java/class.c 2001/02/04 22:44:02 1.88
+++ java/class.c 2001/02/28 05:59:30
@@ -627,7 +627,7 @@ java_hash_hash_tree_node (k)
return (long) k;
}
-boolean
+bool
java_hash_compare_tree_node (k1, k2)
hash_table_key k1;
hash_table_key k2;
===================================================================
Index: java/decl.c
--- java/decl.c 2001/02/23 20:38:56 1.89
+++ java/decl.c 2001/02/28 05:59:31
@@ -47,7 +47,7 @@ static tree push_jvm_slot PARAMS ((int,
static tree lookup_name_current_level PARAMS ((tree));
static tree push_promoted_type PARAMS ((const char *, tree));
static struct binding_level *make_binding_level PARAMS ((void));
-static boolean emit_init_test_initialization PARAMS ((struct hash_entry *,
+static bool emit_init_test_initialization PARAMS ((struct hash_entry *,
hash_table_key));
static tree create_primitive_vtable PARAMS ((const char *));
static tree check_local_named_variable PARAMS ((tree, tree, int, int *));
@@ -1690,7 +1690,7 @@ build_result_decl (fndecl)
/* Called for every element in DECL_FUNCTION_INIT_TEST_TABLE in order
to emit initialization code for each test flag. */
-static boolean
+static bool
emit_init_test_initialization (entry, key)
struct hash_entry *entry;
hash_table_key key ATTRIBUTE_UNUSED;
===================================================================
Index: java/java-tree.h
--- java/java-tree.h 2001/02/24 03:28:39 1.99
+++ java/java-tree.h 2001/02/28 05:59:31
@@ -1109,7 +1109,7 @@ extern void safe_layout_class PARAMS ((t
extern tree get_boehm_type_descriptor PARAMS ((tree));
extern unsigned long java_hash_hash_tree_node PARAMS ((hash_table_key));
-extern boolean java_hash_compare_tree_node PARAMS ((hash_table_key,
+extern bool java_hash_compare_tree_node PARAMS ((hash_table_key,
hash_table_key));
extern void java_check_methods PARAMS ((tree));
extern void init_jcf_parse PARAMS((void));