1*9eab2a37SAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*9eab2a37SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*9eab2a37SAndrew Rist * or more contributor license agreements. See the NOTICE file 5*9eab2a37SAndrew Rist * distributed with this work for additional information 6*9eab2a37SAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*9eab2a37SAndrew Rist * to you under the Apache License, Version 2.0 (the 8*9eab2a37SAndrew Rist * "License"); you may not use this file except in compliance 9*9eab2a37SAndrew Rist * with the License. You may obtain a copy of the License at 10*9eab2a37SAndrew Rist * 11*9eab2a37SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*9eab2a37SAndrew Rist * 13*9eab2a37SAndrew Rist * Unless required by applicable law or agreed to in writing, 14*9eab2a37SAndrew Rist * software distributed under the License is distributed on an 15*9eab2a37SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*9eab2a37SAndrew Rist * KIND, either express or implied. See the License for the 17*9eab2a37SAndrew Rist * specific language governing permissions and limitations 18*9eab2a37SAndrew Rist * under the License. 19*9eab2a37SAndrew Rist * 20*9eab2a37SAndrew Rist *************************************************************/ 21*9eab2a37SAndrew Rist 22*9eab2a37SAndrew Rist 23cdf0e10cSrcweir 24cdf0e10cSrcweir 25cdf0e10cSrcweir #ifndef TRUE 26cdf0e10cSrcweir #define TRUE 1 27cdf0e10cSrcweir #define FALSE 0 28cdf0e10cSrcweir #endif 29cdf0e10cSrcweir 30cdf0e10cSrcweir /* in cpp1.c: file-pointer auf stdout oder file */ 31cdf0e10cSrcweir extern FILE *pCppOut; /* BP */ 32cdf0e10cSrcweir #define PUTCHAR( d ) fprintf( pCppOut, "%c", (d) ) /* BP */ 33cdf0e10cSrcweir #if OSL_DEBUG_LEVEL > 1 34cdf0e10cSrcweir extern FILE *pDefOut; /* ER */ 35cdf0e10cSrcweir #ifdef EVALDEFS 36cdf0e10cSrcweir #define NEVALBUF 2048 37cdf0e10cSrcweir #endif 38cdf0e10cSrcweir #endif 39cdf0e10cSrcweir 40cdf0e10cSrcweir /* limit for reading commandfiles */ 41cdf0e10cSrcweir #define PARALIMIT 100 42cdf0e10cSrcweir 43cdf0e10cSrcweir #ifndef EOS 44cdf0e10cSrcweir /* 45cdf0e10cSrcweir * This is predefined in Decus C 46cdf0e10cSrcweir */ 47cdf0e10cSrcweir #define EOS '\0' /* End of string */ 48cdf0e10cSrcweir #endif 49cdf0e10cSrcweir #define EOF_CHAR 0 /* Returned by get() on eof */ 50cdf0e10cSrcweir #define NULLST ((char *) NULL) /* Pointer to nowhere (linted) */ 51cdf0e10cSrcweir #define DEF_NOARGS (-1) /* #define foo vs #define foo() */ 52cdf0e10cSrcweir 53cdf0e10cSrcweir /* 54cdf0e10cSrcweir * The following may need to change if the host system doesn't use ASCII. 55cdf0e10cSrcweir */ 56cdf0e10cSrcweir #define DEF_MAGIC 0x1D /* Magic for #defines */ 57cdf0e10cSrcweir #define TOK_SEP 0x1E /* Token concatenation delim. */ 58cdf0e10cSrcweir #define COM_SEP 0x1F /* Magic comment separator */ 59cdf0e10cSrcweir 60cdf0e10cSrcweir #ifdef EBCDIC 61cdf0e10cSrcweir #define HT 0x05 /* horizontal tab */ 62cdf0e10cSrcweir #define NL 0x15 /* new line */ 63cdf0e10cSrcweir #define CR 0x0D /* carriage return */ 64cdf0e10cSrcweir #define DEL 0x07 65cdf0e10cSrcweir #else 66cdf0e10cSrcweir #define HT 0x09 /* horizontal tab */ 67cdf0e10cSrcweir #define NL 0x0A /* new line */ 68cdf0e10cSrcweir #define CR 0x0D /* carriage return */ 69cdf0e10cSrcweir #define DEL 0x7F 70cdf0e10cSrcweir #endif 71cdf0e10cSrcweir 72cdf0e10cSrcweir 73cdf0e10cSrcweir #ifdef SOLAR 74cdf0e10cSrcweir #define MAC_PARM 0x01 /* Macro formals start here */ 75cdf0e10cSrcweir #else 76cdf0e10cSrcweir /* 77cdf0e10cSrcweir * Note -- in Ascii, the following will map macro formals onto DEL + the 78cdf0e10cSrcweir * C1 control character region (decimal 128 .. (128 + PAR_MAC)) which will 79cdf0e10cSrcweir * be ok as long as PAR_MAC is less than 33). Note that the last PAR_MAC 80cdf0e10cSrcweir * value is reserved for string substitution. 81cdf0e10cSrcweir */ 82cdf0e10cSrcweir 83cdf0e10cSrcweir #define MAC_PARM DEL /* Macro formals start here */ 84cdf0e10cSrcweir #if PAR_MAC >= 33 85cdf0e10cSrcweir assertion fails -- PAR_MAC is not less than 33 86cdf0e10cSrcweir #endif 87cdf0e10cSrcweir #endif 88cdf0e10cSrcweir #define LASTPARM (PAR_MAC - 1) 89cdf0e10cSrcweir 90cdf0e10cSrcweir /* 91cdf0e10cSrcweir * Character type codes. 92cdf0e10cSrcweir */ 93cdf0e10cSrcweir 94cdf0e10cSrcweir #define INV 0 /* Invalid, must be zero */ 95cdf0e10cSrcweir #define OP_EOE INV /* End of expression */ 96cdf0e10cSrcweir #define DIG 1 /* Digit */ 97cdf0e10cSrcweir #define LET 2 /* Identifier start */ 98cdf0e10cSrcweir #define FIRST_BINOP OP_ADD 99cdf0e10cSrcweir #define OP_ADD 3 100cdf0e10cSrcweir #define OP_SUB 4 101cdf0e10cSrcweir #define OP_MUL 5 102cdf0e10cSrcweir #define OP_DIV 6 103cdf0e10cSrcweir #define OP_MOD 7 104cdf0e10cSrcweir #define OP_ASL 8 105cdf0e10cSrcweir #define OP_ASR 9 106cdf0e10cSrcweir #define OP_AND 10 /* &, not && */ 107cdf0e10cSrcweir #define OP_OR 11 /* |, not || */ 108cdf0e10cSrcweir #define OP_XOR 12 109cdf0e10cSrcweir #define OP_EQ 13 110cdf0e10cSrcweir #define OP_NE 14 111cdf0e10cSrcweir #define OP_LT 15 112cdf0e10cSrcweir #define OP_LE 16 113cdf0e10cSrcweir #define OP_GE 17 114cdf0e10cSrcweir #define OP_GT 18 115cdf0e10cSrcweir #define OP_ANA 19 /* && */ 116cdf0e10cSrcweir #define OP_ORO 20 /* || */ 117cdf0e10cSrcweir #define OP_QUE 21 /* ? */ 118cdf0e10cSrcweir #define OP_COL 22 /* : */ 119cdf0e10cSrcweir #define OP_CMA 23 /* , (relevant?) */ 120cdf0e10cSrcweir #define LAST_BINOP OP_CMA /* Last binary operand */ 121cdf0e10cSrcweir /* 122cdf0e10cSrcweir * The following are unary. 123cdf0e10cSrcweir */ 124cdf0e10cSrcweir #define FIRST_UNOP OP_PLU /* First Unary operand */ 125cdf0e10cSrcweir #define OP_PLU 24 /* + (draft ANSI standard) */ 126cdf0e10cSrcweir #define OP_NEG 25 /* - */ 127cdf0e10cSrcweir #define OP_COM 26 /* ~ */ 128cdf0e10cSrcweir #define OP_NOT 27 /* ! */ 129cdf0e10cSrcweir #define LAST_UNOP OP_NOT 130cdf0e10cSrcweir #define OP_LPA 28 /* ( */ 131cdf0e10cSrcweir #define OP_RPA 29 /* ) */ 132cdf0e10cSrcweir #define OP_END 30 /* End of expression marker */ 133cdf0e10cSrcweir #define OP_MAX (OP_END + 1) /* Number of operators */ 134cdf0e10cSrcweir #define OP_FAIL (OP_END + 1) /* For error returns */ 135cdf0e10cSrcweir 136cdf0e10cSrcweir /* 137cdf0e10cSrcweir * The following are for lexical scanning only. 138cdf0e10cSrcweir */ 139cdf0e10cSrcweir 140cdf0e10cSrcweir #define QUO 65 /* Both flavors of quotation */ 141cdf0e10cSrcweir #define DOT 66 /* . might start a number */ 142cdf0e10cSrcweir #define SPA 67 /* Space and tab */ 143cdf0e10cSrcweir #define BSH 68 /* Just a backslash */ 144cdf0e10cSrcweir #define END 69 /* EOF */ 145cdf0e10cSrcweir 146cdf0e10cSrcweir /* 147cdf0e10cSrcweir * These bits are set in ifstack[] 148cdf0e10cSrcweir */ 149cdf0e10cSrcweir #define WAS_COMPILING 1 /* TRUE if compile set at entry */ 150cdf0e10cSrcweir #define ELSE_SEEN 2 /* TRUE when #else processed */ 151cdf0e10cSrcweir #define TRUE_SEEN 4 /* TRUE when #if TRUE processed */ 152cdf0e10cSrcweir 153cdf0e10cSrcweir /* 154cdf0e10cSrcweir * Define bits for the basic types and their adjectives 155cdf0e10cSrcweir */ 156cdf0e10cSrcweir 157cdf0e10cSrcweir #define T_CHAR 1 158cdf0e10cSrcweir #define T_INT 2 159cdf0e10cSrcweir #define T_FLOAT 4 160cdf0e10cSrcweir #define T_DOUBLE 8 161cdf0e10cSrcweir #define T_SHORT 16 162cdf0e10cSrcweir #define T_LONG 32 163cdf0e10cSrcweir #define T_SIGNED 64 164cdf0e10cSrcweir #define T_UNSIGNED 128 165cdf0e10cSrcweir #define T_PTR 256 /* Pointer */ 166cdf0e10cSrcweir #define T_FPTR 512 /* Pointer to functions */ 167cdf0e10cSrcweir 168cdf0e10cSrcweir /* 169cdf0e10cSrcweir * The DEFBUF structure stores information about #defined 170cdf0e10cSrcweir * macros. Note that the defbuf->repl information is always 171cdf0e10cSrcweir * in malloc storage. 172cdf0e10cSrcweir */ 173cdf0e10cSrcweir 174cdf0e10cSrcweir typedef struct defbuf { 175cdf0e10cSrcweir struct defbuf *link; /* Next define in chain */ 176cdf0e10cSrcweir char *repl; /* -> replacement */ 177cdf0e10cSrcweir int hash; /* Symbol table hash */ 178cdf0e10cSrcweir int nargs; /* For define(args) */ 179cdf0e10cSrcweir char name[1]; /* #define name */ 180cdf0e10cSrcweir } DEFBUF; 181cdf0e10cSrcweir 182cdf0e10cSrcweir /* 183cdf0e10cSrcweir * The FILEINFO structure stores information about open files 184cdf0e10cSrcweir * and macros being expanded. 185cdf0e10cSrcweir */ 186cdf0e10cSrcweir 187cdf0e10cSrcweir typedef struct fileinfo { 188cdf0e10cSrcweir char *bptr; /* Buffer pointer */ 189cdf0e10cSrcweir int line; /* for include or macro */ 190cdf0e10cSrcweir FILE *fp; /* File if non-null */ 191cdf0e10cSrcweir struct fileinfo *parent; /* Link to includer */ 192cdf0e10cSrcweir char *filename; /* File/macro name */ 193cdf0e10cSrcweir char *progname; /* From #line statement */ 194cdf0e10cSrcweir unsigned int unrecur; /* For macro recursion */ 195cdf0e10cSrcweir char buffer[1]; /* current input line */ 196cdf0e10cSrcweir } FILEINFO; 197cdf0e10cSrcweir 198cdf0e10cSrcweir /* 199cdf0e10cSrcweir * The SIZES structure is used to store the values for #if sizeof 200cdf0e10cSrcweir */ 201cdf0e10cSrcweir 202cdf0e10cSrcweir typedef struct sizes { 203cdf0e10cSrcweir short bits; /* If this bit is set, */ 204cdf0e10cSrcweir int size; /* this is the datum size value */ 205cdf0e10cSrcweir int psize; /* this is the pointer size */ 206cdf0e10cSrcweir } SIZES; 207cdf0e10cSrcweir /* 208cdf0e10cSrcweir * nomacarg is a built-in #define on Decus C. 209cdf0e10cSrcweir */ 210cdf0e10cSrcweir 211cdf0e10cSrcweir #ifdef nomacarg 212cdf0e10cSrcweir #define cput output /* cput concatenates tokens */ 213cdf0e10cSrcweir #else 214cdf0e10cSrcweir #if COMMENT_INVISIBLE 215cdf0e10cSrcweir #define cput(c) { if (c != TOK_SEP && c != COM_SEP) PUTCHAR(c); } 216cdf0e10cSrcweir #else 217cdf0e10cSrcweir #define cput(c) { if (c != TOK_SEP) PUTCHAR(c); } 218cdf0e10cSrcweir #endif 219cdf0e10cSrcweir #endif 220cdf0e10cSrcweir 221cdf0e10cSrcweir #ifndef nomacarg 222cdf0e10cSrcweir #define streq(s1, s2) (strcmp(s1, s2) == 0) 223cdf0e10cSrcweir #endif 224cdf0e10cSrcweir 225cdf0e10cSrcweir /* 226cdf0e10cSrcweir * Error codes. VMS uses system definitions. 227cdf0e10cSrcweir * Decus C codes are defined in stdio.h. 228cdf0e10cSrcweir * Others are cooked to order. 229cdf0e10cSrcweir */ 230cdf0e10cSrcweir 231cdf0e10cSrcweir #if HOST == SYS_VMS 232cdf0e10cSrcweir #include <ssdef.h> 233cdf0e10cSrcweir #include <stsdef.h> 234cdf0e10cSrcweir #define IO_NORMAL (SS$_NORMAL | STS$M_INHIB_MSG) 235cdf0e10cSrcweir #define IO_ERROR SS$_ABORT 236cdf0e10cSrcweir #endif 237cdf0e10cSrcweir /* 238cdf0e10cSrcweir * Note: IO_NORMAL and IO_ERROR are defined in the Decus C stdio.h file 239cdf0e10cSrcweir */ 240cdf0e10cSrcweir #ifndef IO_NORMAL 241cdf0e10cSrcweir #define IO_NORMAL 0 242cdf0e10cSrcweir #endif 243cdf0e10cSrcweir #ifndef IO_ERROR 244cdf0e10cSrcweir #define IO_ERROR 1 245cdf0e10cSrcweir #endif 246cdf0e10cSrcweir 247cdf0e10cSrcweir /* 248cdf0e10cSrcweir * Externs 249cdf0e10cSrcweir */ 250cdf0e10cSrcweir 251cdf0e10cSrcweir extern int line; /* Current line number */ 252cdf0e10cSrcweir extern int wrongline; /* Force #line to cc pass 1 */ 253cdf0e10cSrcweir extern char type[]; /* Character classifier */ 254cdf0e10cSrcweir extern char token[IDMAX + 1]; /* Current input token */ 255cdf0e10cSrcweir extern int instring; /* TRUE if scanning string */ 256cdf0e10cSrcweir extern int inmacro; /* TRUE if scanning #define */ 257cdf0e10cSrcweir extern int errors; /* Error counter */ 258cdf0e10cSrcweir extern int recursion; /* Macro depth counter */ 259cdf0e10cSrcweir extern char ifstack[BLK_NEST]; /* #if information */ 260cdf0e10cSrcweir #define compiling ifstack[0] 261cdf0e10cSrcweir extern char *ifptr; /* -> current ifstack item */ 262cdf0e10cSrcweir extern char *incdir[NINCLUDE]; /* -i directories */ 263cdf0e10cSrcweir extern char **incend; /* -> active end of incdir */ 264cdf0e10cSrcweir extern int cflag; /* -C option (keep comments) */ 265cdf0e10cSrcweir extern int eflag; /* -E option (ignore errors) */ 266cdf0e10cSrcweir extern int nflag; /* -N option (no pre-defines) */ 267cdf0e10cSrcweir extern int rec_recover; /* unwind recursive macros */ 268cdf0e10cSrcweir extern char *preset[]; /* Standard predefined symbols */ 269cdf0e10cSrcweir extern char *magic[]; /* Magic predefined symbols */ 270cdf0e10cSrcweir extern FILEINFO *infile; /* Current input file */ 271cdf0e10cSrcweir extern char work[NWORK + 1]; /* #define scratch */ 272cdf0e10cSrcweir extern char *workp; /* Free space in work */ 273cdf0e10cSrcweir #if OSL_DEBUG_LEVEL > 1 274cdf0e10cSrcweir extern int debug; /* Debug level */ 275cdf0e10cSrcweir /* ER dump & evaluate #define's */ 276cdf0e10cSrcweir extern int bDumpDefs; /* TRUE if #define's dump req. */ 277cdf0e10cSrcweir extern int bIsInEval; /* TRUE if #define dumping now */ 278cdf0e10cSrcweir #ifdef EVALDEFS 279cdf0e10cSrcweir extern char EvalBuf[NEVALBUF + 1]; /* evaluation buffer */ 280cdf0e10cSrcweir extern int nEvalOff; /* offset to free buffer pos */ 281cdf0e10cSrcweir #endif 282cdf0e10cSrcweir #endif 283cdf0e10cSrcweir extern int keepcomments; /* Don't remove comments if set */ 284cdf0e10cSrcweir extern SIZES size_table[]; /* For #if sizeof sizes */ 285cdf0e10cSrcweir 286cdf0e10cSrcweir #ifdef NOMAIN /* BP */ 287cdf0e10cSrcweir #ifndef _NO_PROTO 288cdf0e10cSrcweir int start_cpp( int argc, char *argv[] ); 289cdf0e10cSrcweir #endif 290cdf0e10cSrcweir #define MAIN start_cpp /* fuer die cpp.lib muss main() geandert werden */ 291cdf0e10cSrcweir #else 292cdf0e10cSrcweir #ifdef WNT 293cdf0e10cSrcweir #define MAIN __cdecl main 294cdf0e10cSrcweir #else 295cdf0e10cSrcweir #define MAIN main 296cdf0e10cSrcweir #endif 297cdf0e10cSrcweir #endif 298cdf0e10cSrcweir 299cdf0e10cSrcweir 300cdf0e10cSrcweir void InitCpp1(); 301cdf0e10cSrcweir void InitCpp2(); 302cdf0e10cSrcweir void InitCpp3(); 303cdf0e10cSrcweir void InitCpp4(); 304cdf0e10cSrcweir void InitCpp5(); 305cdf0e10cSrcweir void InitCpp6(); 306cdf0e10cSrcweir 307cdf0e10cSrcweir #define HELLO() fprintf( stderr, "[Hello at %s, %d] ", __FILE__, __LINE__ ) 308cdf0e10cSrcweir 309cdf0e10cSrcweir #ifndef _STDIO_H 310cdf0e10cSrcweir #include <stdio.h> 311cdf0e10cSrcweir #endif 312cdf0e10cSrcweir 313cdf0e10cSrcweir #ifndef _STDLIB_H 314cdf0e10cSrcweir #include <stdlib.h> 315cdf0e10cSrcweir #endif 316cdf0e10cSrcweir 317cdf0e10cSrcweir #ifndef _STRING_H 318cdf0e10cSrcweir #include <string.h> 319cdf0e10cSrcweir #endif 320cdf0e10cSrcweir 321cdf0e10cSrcweir /* cpp1.c */ 322cdf0e10cSrcweir void output( int c ); 323cdf0e10cSrcweir void sharp(); 324cdf0e10cSrcweir void cppmain(); 325cdf0e10cSrcweir #if OSL_DEBUG_LEVEL > 1 326cdf0e10cSrcweir #ifdef EVALDEFS 327cdf0e10cSrcweir int outputEval( int c ); 328cdf0e10cSrcweir #endif 329cdf0e10cSrcweir #endif 330cdf0e10cSrcweir 331cdf0e10cSrcweir 332cdf0e10cSrcweir /* cpp2.c */ 333cdf0e10cSrcweir int control( int counter ); 334cdf0e10cSrcweir void doinclude(); 335cdf0e10cSrcweir void dodefine(); 336cdf0e10cSrcweir void doif( int hash ); 337cdf0e10cSrcweir int openinclude( char *, int ); 338cdf0e10cSrcweir int hasdirectory(char *, char * ); 339cdf0e10cSrcweir int openfile( char * ); 340cdf0e10cSrcweir 341cdf0e10cSrcweir /* cpp3.c */ 342cdf0e10cSrcweir int openfiles( char *filename ); 343cdf0e10cSrcweir void addfile( FILE *fp, char *filename ); 344cdf0e10cSrcweir void setincdirs(); 345cdf0e10cSrcweir int AddInclude( char *pIncStr ); 346cdf0e10cSrcweir int getredirection( int argc, char **argv ); 347cdf0e10cSrcweir void zap_uc( char *ap ); 348cdf0e10cSrcweir 349cdf0e10cSrcweir void initdefines(); 350cdf0e10cSrcweir int dooptions( int argc, char *argv[] ); 351cdf0e10cSrcweir int readoptions(char* filename, char*** pfargv); 352cdf0e10cSrcweir 353cdf0e10cSrcweir /* cpp4.c */ 354cdf0e10cSrcweir void dodefines(); 355cdf0e10cSrcweir void checkparm( int c, DEFBUF *dp ); 356cdf0e10cSrcweir int expcollect(); 357cdf0e10cSrcweir void expstuff( DEFBUF *dp ); 358cdf0e10cSrcweir 359cdf0e10cSrcweir #if STRING_FORMAL 360cdf0e10cSrcweir void stparmscan( int delim, DEFBUF *dp); 361cdf0e10cSrcweir #else 362cdf0e10cSrcweir void stparmscan( int delim); 363cdf0e10cSrcweir #endif 364cdf0e10cSrcweir #if OSL_DEBUG_LEVEL > 1 365cdf0e10cSrcweir void dumpparm( char *why ); 366cdf0e10cSrcweir #endif 367cdf0e10cSrcweir 368cdf0e10cSrcweir void doundef(); 369cdf0e10cSrcweir void textput( char *text ); 370cdf0e10cSrcweir void charput( int c ); 371cdf0e10cSrcweir void expand( DEFBUF *tokenp ); 372cdf0e10cSrcweir 373cdf0e10cSrcweir /* cpp5.c */ 374cdf0e10cSrcweir int eval(); 375cdf0e10cSrcweir int evallex(int); 376cdf0e10cSrcweir int *evaleval(int *, int, int ); 377cdf0e10cSrcweir int evalchar(int); 378cdf0e10cSrcweir int dosizeof(); 379cdf0e10cSrcweir int evalnum( int c ); 380cdf0e10cSrcweir int bittest( int ); 381cdf0e10cSrcweir 382cdf0e10cSrcweir /* cpp6.c */ 383cdf0e10cSrcweir 384cdf0e10cSrcweir void skipnl(); 385cdf0e10cSrcweir int skipws(); 386cdf0e10cSrcweir void scanid( int c ); 387cdf0e10cSrcweir int macroid( int c ); 388cdf0e10cSrcweir int catenate(); 389cdf0e10cSrcweir int scanstring( int c, void (*outfun)( int c ) ); 390cdf0e10cSrcweir void scannumber( int c, void (*outfun)( int c ) ); 391cdf0e10cSrcweir void save( int c ); 392cdf0e10cSrcweir char *savestring( char *text ); 393cdf0e10cSrcweir FILEINFO *getfile( int bufsize, char *name); 394cdf0e10cSrcweir char *getmem( int size ); 395cdf0e10cSrcweir DEFBUF *lookid( int c ); 396cdf0e10cSrcweir DEFBUF *defendel( char *name, int delete ); 397cdf0e10cSrcweir void dunpdef( char *why ); 398cdf0e10cSrcweir void dumpadef( char *why, DEFBUF *dp); 399cdf0e10cSrcweir int get(); 400cdf0e10cSrcweir int cget(); 401cdf0e10cSrcweir void unget(); 402cdf0e10cSrcweir void ungetstring( char *text ); 403cdf0e10cSrcweir void cerror( char *format, char *sarg); 404cdf0e10cSrcweir void cwarn( char *format, char *sarg); 405cdf0e10cSrcweir void cfatal( char *format, char *sarg); 406cdf0e10cSrcweir void cierror( char *format, int n); 407cdf0e10cSrcweir void ciwarn( char *format, int n); 408cdf0e10cSrcweir #if OSL_DEBUG_LEVEL > 1 409cdf0e10cSrcweir void dumpdef( char *why ); 410cdf0e10cSrcweir void dumpadef( char *why, DEFBUF *dp ); 411cdf0e10cSrcweir #endif 412