home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / historic / v92.tgz / v92.tar / v92 / src / iconc / ctrans.h < prev    next >
C/C++ Source or Header  |  1996-03-22  |  1KB  |  49 lines

  1. /*
  2.  *  Miscellaneous compiler-specific definitions.
  3.  */
  4.  
  5. #define Iconc
  6.  
  7. #ifdef strlen
  8. #undef strlen            /* defined in some contexts */
  9. #endif /* strlen */
  10.  
  11. #define Abs(n) ((n) >= 0 ? (n) : -(n))
  12. #define Max(x,y) ((x)>(y)?(x):(y))
  13.  
  14. #if !EBCDIC
  15. #define tonum(c)    (isdigit(c) ? (c - '0') : ((c & 037) + 9))
  16. #endif                    /* !EBCDIC */
  17.  
  18. /*
  19.  * Hash tables must be a power of 2.
  20.  */
  21. #define CHSize 128    /* size of constant hash table */
  22. #define FHSize  32    /* size of field hash table */
  23. #define GHSize 128    /* size of global hash table */
  24. #define LHSize 128    /* size of local hash table */
  25.  
  26. #define PrfxSz 3        /* size of prefix */
  27.  
  28. /*
  29.  * srcfile is used construct the queue of source files to be translated.
  30.  */
  31. struct srcfile {
  32.    char *name;
  33.    struct srcfile *next;
  34.    };
  35.  
  36. extern struct srcfile *srclst;
  37.  
  38. /*
  39.  * External definitions needed throughout translator.
  40.  */
  41. extern int twarns;
  42.  
  43. #ifdef TranStats
  44. #include "tstats.h"
  45. #else                    /* TranStats */
  46. #define TokInc(x)
  47. #define TokDec(x)
  48. #endif                    /* TranStats */
  49.