1 /* Id: ftypes.h,v 1.5 2008/12/19 08:08:48 ragge Exp */ 2 /* $NetBSD: ftypes.h,v 1.1.1.3 2010/06/03 18:57:48 plunky Exp $ */ 3 /* 4 * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: 9 * 10 * Redistributions of source code and documentation must retain the above 11 * copyright notice, this list of conditions and the following disclaimer. 12 * Redistributions in binary form must reproduce the above copyright 13 * notice, this list of conditionsand the following disclaimer in the 14 * documentation and/or other materials provided with the distribution. 15 * All advertising materials mentioning features or use of this software 16 * must display the following acknowledgement: 17 * This product includes software developed or owned by Caldera 18 * International, Inc. 19 * Neither the name of Caldera International, Inc. nor the names of other 20 * contributors may be used to endorse or promote products derived from 21 * this software without specific prior written permission. 22 * 23 * USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA 24 * INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR 25 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 26 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 27 * DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE LIABLE 28 * FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 30 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 31 * HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, 32 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING 33 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 34 * POSSIBILITY OF SUCH DAMAGE. 35 */ 36 /* variable types 37 * numeric assumptions: 38 * int < reals < complexes 39 * TYDREAL-TYREAL = TYDCOMPLEX-TYCOMPLEX 40 */ 41 42 #ifndef _FTYPES_H_ 43 #define _FTYPES_H_ 44 45 46 #define TYUNKNOWN 0 47 #define TYADDR 1 48 #define TYSHORT 2 49 #define TYLONG 3 50 #define TYREAL 4 51 #define TYDREAL 5 52 #define TYCOMPLEX 6 53 #define TYDCOMPLEX 7 54 #define TYLOGICAL 8 55 #define TYCHAR 9 56 #define TYSUBR 10 57 #define TYERROR 11 58 59 #define NTYPES (TYERROR+1) 60 61 /* 62 * Type conversion from pcc to f77 internal format. 63 */ 64 #define FSZADDR (SZPOINT(0)/SZCHAR) /* XXX - typecheck? */ 65 #define FSZSHORT (SZSHORT/SZCHAR) 66 #define FSZINT (SZINT/SZCHAR) 67 #define FSZLONG (SZLONG/SZCHAR) 68 #define ALIADDR (ALPOINT/ALCHAR) 69 #define ALISHORT (ALSHORT/ALCHAR) 70 #define ALILONG (ALLONG/ALCHAR) 71 #define ALIDOUBLE (ALDOUBLE/ALCHAR) 72 73 #ifndef SZINT 74 #include "macdefs.h" 75 #endif 76 #if SZINT == SZSHORT 77 #define TYINT TYSHORT 78 #else /* SZLONG >= SZINT */ 79 #define TYINT TYLONG 80 #endif 81 82 #define TYLENG TYLONG 83 #endif /* !_FTYPES_H_ */ 84