X-Git-Url: http://git.kpe.io/?p=ctsim.git;a=blobdiff_plain;f=include%2Fpol.h;h=808b3803a45ea85282eb2cec78ef3b8656483e0f;hp=262cccbc1c93aa557ac4374d66733c04db7e7e58;hb=5c6b29ab4885308cc3381af6e0a68f4804956d2e;hpb=c24c1c0721df40e77822ad2b9ec01a944012ff42 diff --git a/include/pol.h b/include/pol.h index 262cccb..808b380 100644 --- a/include/pol.h +++ b/include/pol.h @@ -2,7 +2,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: pol.h,v 1.8 2000/12/27 20:09:19 kevin Exp $ +** $Id: pol.h,v 1.9 2000/12/29 15:45:06 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -21,7 +21,7 @@ #define __H_POL #include "hashtable.h" - +#include class POL { @@ -167,6 +167,17 @@ private: PC_DUMP, }; + enum { + INPUT_STREAM = 1, + INPUT_FILE, + INPUT_STRING, + }; + + int m_iInputType; + std::istream* m_pInputStream; + FILE* m_pInputFile; + char* m_pszInputString; + enum { MAXFILE = 8, }; @@ -178,12 +189,8 @@ private: char inputline[MAXLINE]; /* current input line */ int lineptr; /* current position in inputline */ - enum { - BUFSIZE = 100, - }; - int bp; // pointer to next free position - int buf[BUFSIZE]; // pushed back input characters - + std::stack m_stackPushBackInput; + bool skipSingleToken (char term[]); int tok (struct token_st *token); void dumptok (struct token_st *token);