[BACK]Return to parse.h CVS log [TXT][DIR] Up to [local] / OpenXM / src / ox_math

Annotation of OpenXM/src/ox_math/parse.h, Revision 1.5

1.1       ohara       1: /* -*- mode: C; coding: euc-japan -*- */
1.5     ! ohara       2: /* $OpenXM: OpenXM/src/ox_math/parse.h,v 1.4 1999/11/06 21:39:37 ohara Exp $ */
1.1       ohara       3:
                      4: #ifndef _PARSE_H_
                      5:
                      6: #include "ox.h"
                      7:
                      8: #define _PARSE_H_
                      9:
1.2       ohara      10: /* トークンの定義 */
                     11: /* 256 より小さいものは、一文字だけのトークンである */
1.1       ohara      12:
                     13: #define T_INTEGER       257
                     14: #define T_STRING        258
1.2       ohara      15: #define T_MAGIC         2048
                     16: #define TOKEN(x)        (T_MAGIC + (x))
1.3       ohara      17: #define SM              SM_popCMO
1.1       ohara      18:
1.2       ohara      19: /* トークンの種類を判定するためのマクロ */
                     20: #define MIN_T_CMO     TOKEN(0)
                     21: #define MAX_T_CMO     TOKEN(256)
                     22: #define MIN_T_OX      TOKEN(512)
                     23: #define MAX_T_OX      TOKEN(600)
1.1       ohara      24:
1.4       ohara      25: #define IS_CMO   1
                     26: #define IS_SM    2
                     27: #define IS_OX    3
                     28:
1.2       ohara      29: #define PFLAG_ADDREV   1
                     30: int setflag_parse(int flag);
1.1       ohara      31:
                     32: cmo *parse();
                     33:
                     34: int setgetc(int (*foo)());
                     35: int resetgetc();
                     36: int mygetc();
                     37: int setmode_mygetc(char *s, int len);
1.4       ohara      38:
                     39: typedef struct {
1.5     ! ohara      40:     char *key;
        !            41:     int  tag;
        !            42:     int  token;
        !            43:     int  type;
1.4       ohara      44: } symbol;
1.5     ! ohara      45:
        !            46: symbol* lookup_by_symbol(char *key);
        !            47: symbol* lookup_by_token(int tok);
        !            48: symbol* lookup_by_tag(int tag);
        !            49: symbol* lookup(int i);
1.1       ohara      50:
                     51: #endif /* _PARSE_H_ */

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>