*** empty log message ***
This commit is contained in:
parent
debef378c9
commit
be68581019
|
@ -72,10 +72,13 @@ all: cc
|
|||
cc: hfiles LLfiles
|
||||
make "EMHOME="$(EMHOME) cpp
|
||||
|
||||
hfiles: Parameters
|
||||
hfiles: Parameters char.c charoffset.h
|
||||
./make.hfiles Parameters
|
||||
@touch hfiles
|
||||
|
||||
charoffset.h char.c: chtab char.tab
|
||||
chtab -fchar.tab > char.c
|
||||
|
||||
LLfiles: $(LSRC)
|
||||
$(GEN) $(GENOPTIONS) $(LSRC)
|
||||
@touch LLfiles
|
||||
|
@ -86,12 +89,6 @@ tokenfile.g: tokenname.c make.tokfile
|
|||
symbol2str.c: tokenname.c make.tokcase
|
||||
<tokenname.c ./make.tokcase >symbol2str.c
|
||||
|
||||
char.c: char.tab chtab
|
||||
chtab -fchar.tab > char.c
|
||||
|
||||
charoffset.h: chtab char.tab
|
||||
chtab -fchar.tab > /dev/null
|
||||
|
||||
chtab: chtab.o
|
||||
$(CC) -o chtab chtab.o
|
||||
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
!File: strsize.h
|
||||
#define ISTRSIZE 32 /* minimum number of bytes allocated for
|
||||
storing a string */
|
||||
#define RSTRSIZE 8 /* step size in enlarging the memory for
|
||||
#define RSTRSIZE 32 /* step size in enlarging the memory for
|
||||
the storage of a string */
|
||||
|
||||
|
||||
|
@ -52,8 +52,8 @@
|
|||
|
||||
|
||||
!File: textsize.h
|
||||
#define ITEXTSIZE 32 /* 1st piece of memory for repl. text */
|
||||
#define RTEXTSIZE 32 /* stepsize for enlarging repl.text */
|
||||
#define ITEXTSIZE 64 /* 1st piece of memory for repl. text */
|
||||
#define RTEXTSIZE 64 /* stepsize for enlarging repl.text */
|
||||
|
||||
|
||||
!File: inputtype.h
|
||||
|
|
|
@ -16,6 +16,11 @@ char _obuf[OBUFSIZE];
|
|||
char bits[128];
|
||||
#endif
|
||||
|
||||
Xflush()
|
||||
{
|
||||
sys_write(STDOUT, _obuf, OBUFSIZE);
|
||||
}
|
||||
|
||||
preprocess(fn)
|
||||
char *fn;
|
||||
{
|
||||
|
@ -25,8 +30,8 @@ preprocess(fn)
|
|||
int lineno = 0;
|
||||
extern char options[];
|
||||
|
||||
#define flush(X) (sys_write(STDOUT,_obuf,X), op = _obuf)
|
||||
#define echo(ch) (op != ob || flush(OBUFSIZE), *op++ = (ch))
|
||||
#define flush(X) (sys_write(STDOUT,_obuf,X))
|
||||
#define echo(ch) if (op == ob) { Xflush(); op = _obuf; } *op++ = (ch);
|
||||
#define newline() echo('\n')
|
||||
|
||||
for (;;) {
|
||||
|
@ -48,7 +53,9 @@ preprocess(fn)
|
|||
lineno = LineNumber;
|
||||
sprint(p, "#line %d \"%s\"\n", LineNumber,
|
||||
FileName);
|
||||
while (*p) echo(*p++);
|
||||
while (*p) {
|
||||
echo(*p++);
|
||||
}
|
||||
}
|
||||
for (;;) {
|
||||
if (c & 0200) {
|
||||
|
@ -78,17 +85,23 @@ preprocess(fn)
|
|||
return;
|
||||
}
|
||||
else if (c == '*') {
|
||||
if (options['C']) echo(c);
|
||||
if (options['C']) {
|
||||
echo(c);
|
||||
}
|
||||
LoadChar(c);
|
||||
if (c == '/') {
|
||||
if (options['C']) echo(c);
|
||||
break;
|
||||
if (options['C']) {
|
||||
echo(c);
|
||||
}
|
||||
break;
|
||||
}
|
||||
else {
|
||||
PushBack();
|
||||
}
|
||||
}
|
||||
else if (options['C']) echo(c);
|
||||
else if (options['C']) {
|
||||
echo(c);
|
||||
}
|
||||
}
|
||||
NoUnstack--;
|
||||
LoadChar(c);
|
||||
|
@ -189,7 +202,9 @@ preprocess(fn)
|
|||
nomac:
|
||||
*tg = 0;
|
||||
tg = buf;
|
||||
while (*tg) echo(*tg++);
|
||||
while (*tg) {
|
||||
echo(*tg++);
|
||||
}
|
||||
LoadChar(c);
|
||||
while (in_idf(c)) {
|
||||
echo(c);
|
||||
|
|
Loading…
Reference in a new issue