diff options
author | Mark Mitchell <mark@codesourcery.com> | 2000-04-12 22:08:32 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 2000-04-12 22:08:32 +0000 |
commit | aea0083a2d142590d6468a02a03c0f5c43e75973 (patch) | |
tree | 2ae504567fbf7119524a231d95635ef563c53bce /gcc | |
parent | d7bf8ada06726b45cc1a153bc561b843cefa93bc (diff) | |
download | gcc-aea0083a2d142590d6468a02a03c0f5c43e75973.zip gcc-aea0083a2d142590d6468a02a03c0f5c43e75973.tar.gz gcc-aea0083a2d142590d6468a02a03c0f5c43e75973.tar.bz2 |
com.h (FFECOM_f2cINTEGER): Avoid using LONG_TYPE_SIZE as a preprocessor constant.
* com.h (FFECOM_f2cINTEGER): Avoid using LONG_TYPE_SIZE as a
preprocessor constant.
(FFECOM_f2cLOGICAL): Likewise.
(FFECOM_f2cLONGINT): Likewise.
From-SVN: r33130
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/f/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/f/com.h | 34 |
2 files changed, 23 insertions, 18 deletions
diff --git a/gcc/f/ChangeLog b/gcc/f/ChangeLog index 84eb54a..9d7b76e 100644 --- a/gcc/f/ChangeLog +++ b/gcc/f/ChangeLog @@ -1,3 +1,10 @@ +Wed Apr 12 15:15:26 2000 Mark Mitchell <mark@codesourcery.com> + + * com.h (FFECOM_f2cINTEGER): Avoid using LONG_TYPE_SIZE as a + preprocessor constant. + (FFECOM_f2cLOGICAL): Likewise. + (FFECOM_f2cLONGINT): Likewise. + Wed Apr 5 17:46:39 2000 Mark Mitchell <mark@codesourcery.com> * Makefile.in (GGC_H): Add varray.h. diff --git a/gcc/f/com.h b/gcc/f/com.h index 99c5503..2bb118b 100644 --- a/gcc/f/com.h +++ b/gcc/f/com.h @@ -1,5 +1,5 @@ /* com.h -- Public #include File (module.h template V1.0) - Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc. + Copyright (C) 1995, 1996, 1997, 2000 Free Software Foundation, Inc. Contributed by James Craig Burley. This file is part of GNU Fortran. @@ -127,23 +127,21 @@ the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA #define LONG_DOUBLE_TYPE_SIZE (BITS_PER_WORD * 2) #endif -#if LONG_TYPE_SIZE == FLOAT_TYPE_SIZE -# define FFECOM_f2cINTEGER FFECOM_f2ccodeLONG -# define FFECOM_f2cLOGICAL FFECOM_f2ccodeLONG -#elif INT_TYPE_SIZE == FLOAT_TYPE_SIZE -# define FFECOM_f2cINTEGER FFECOM_f2ccodeINT -# define FFECOM_f2cLOGICAL FFECOM_f2ccodeINT -#else -# error Cannot find a suitable type for FFECOM_f2cINTEGER -#endif - -#if LONG_TYPE_SIZE == (FLOAT_TYPE_SIZE * 2) -# define FFECOM_f2cLONGINT FFECOM_f2ccodeLONG -#elif LONG_LONG_TYPE_SIZE == (FLOAT_TYPE_SIZE * 2) -# define FFECOM_f2cLONGINT FFECOM_f2ccodeLONGLONG -#else -# error Cannot find a suitable type for FFECOM_f2cLONGINT -#endif +#define FFECOM_f2cINTEGER \ + (LONG_TYPE_SIZE == FLOAT_TYPE_SIZE \ + ? FFECOM_f2ccodeLONG \ + : (INT_TYPE_SIZE == FLOAT_TYPE_SIZE \ + ? FFECOM_f2ccodeINT \ + : (abort (), -1))) + +#define FFECOM_f2cLOGICAL FFECOM_f2cINTEGER + +#define FFECOM_f2cLONGINT \ + (LONG_TYPE_SIZE == (FLOAT_TYPE_SIZE * 2) \ + ? FFECOM_f2ccodeLONG \ + : (LONG_LONG_TYPE_SIZE == (FLOAT_TYPE_SIZE * 2) \ + ? FFECOM_f2ccodeLONGLONG \ + : (abort (), -1))) #define FFECOM_f2cADDRESS FFECOM_f2ccodeCHARPTR #define FFECOM_f2cSHORTINT FFECOM_f2ccodeSHORT |