```   1: /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1984. */
2: /* \$Header: b2syn.h,v 1.1 84/06/28 00:48:52 timo Exp \$ */
3:
4: /* bsyn.h: syntax */
5:
6: /* General parsing routines */
7:
8: #define Eotc '\0'
9: #define Eouc '\036'
10:         /* The character Eotc (end of text char)		*/
11:         /* is placed after the last read character in txbuf.	*/
12:         /* In general it follows a newline.			*/
13:         /* If Eotc is encountered and more input is required,	*/
14:         /* getline() is called.					*/
15:         /* Eouc (end of unit char) is similar except the system	*/
16:         /* never has to read beyond it.				*/
17:
18: #define Char(tx) (*(tx))
19: #define Eol(tx) (Char(tx) == '\n' || Char(tx) == Eouc)
20: #define Ceol(tx) (Char(tx) == '\\' || Eol(tx))
21: #define To_eol(tx) while (!Eol(tx)) tx++;
22: #define Mark_unit_end(tx) *tx= Eouc;
23:
24: #define Space(c) ((c) == ' ' || (c) == '\t')
25: #define Skipsp(tx) while(Space(Char(tx))) tx++
26:
27: #define Letter(c) ('a'<=c&&c<='z')
28: #define Cap(c) ('A'<=c&&c<='Z')
29: #define Dig(c) ('0'<=c&&c<='9')
30: #define Keymark(c) (Cap(c) || Dig(c) || c=='\'' || c=='"')
31: #define Tagmark(c) (Letter(c) || Dig(c) || c=='\'' || c=='"')
32: #define Keytagmark(c) (Keymark(c) || Letter(c))
33: #define Anytormark(c) (c=='+' || c=='-' || c=='*' || c=='/' || c=='#')
34: #define Montormark(c) (c=='~' || Anytormark(c))
35: #define Dyatormark(c) (Anytormark(c) || c=='^' || c=='<' || c=='>')
36:
37: /* Procedure upto(); */
38: /* Procedure need(); */
39: /* Procedure nothing(); */
40: /* Procedure thought(); */
41: /* Procedure findceol(); */
42: bool ateol();
43:
44: value findkw();
45: value keyword();
46: /* Procedure reqkw(); */
47: /* Procedure req(); */
48: value tag();
49:
50: bool atkw();
51: bool find();
52: intlet count();
53:
54: txptr fcol();
55: txptr lcol();
56: extern intlet alino;
57: extern txptr txstart, txend; /*TEMPORARY if possible*/
58:
59: /* Procedure getline(); */
60: intlet ilev();
61: /* Procedure veli(); */
62: /* Procedure inistreams(); */
63: /* Procedure re_streams(); */
64: /* Procedure open_stream(); */
65: /* Procedure close_stream(); */
```

#### Defined macros

Anytormark defined in line 33; used 2 times
Dig defined in line 29; used 9 times
Dyatormark defined in line 35; used 2 times
Eouc defined in line 9; used 8 times
Keytagmark defined in line 32; used 1 times
Mark_unit_end defined in line 22; used 2 times
Space defined in line 24; used 3 times

#### Usage of this include

 Last modified: 1985-08-27 Generated: 2016-12-26 Generated by src2html V0.67 page hit count: 2260