From d50e5fae41679ef71d2965477e0ea475ee934f80 Mon Sep 17 00:00:00 2001 From: Jonas Lund Date: Sun, 22 Nov 2015 22:26:15 +0100 Subject: [PATCH] Rename outp to outptr to avoid name clash with MSVC --- cpp/cpp.c | 4 ++-- cpp/cpp.h | 2 +- cpp/include.c | 6 +++--- cpp/macro.c | 10 +++++----- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/cpp/cpp.c b/cpp/cpp.c index 1e5d0125..bad6f755 100755 --- a/cpp/cpp.c +++ b/cpp/cpp.c @@ -7,7 +7,7 @@ #define OUTS 16384 char outbuf[OUTS]; -char *outp = outbuf; +char *outptr = outbuf; Source *cursource; int nerrs; struct token nltoken = { NL, 0, 0, 0, 1, (uchar*)"\n" }; @@ -50,7 +50,7 @@ process(Tokenrow *trp) for (;;) { if (trp->tp >= trp->lp) { trp->tp = trp->lp = trp->bp; - outp = outbuf; + outptr = outbuf; anymacros |= gettokens(trp, 1); trp->tp = trp->bp; } diff --git a/cpp/cpp.h b/cpp/cpp.h index b1ff8b88..7ceccd32 100755 --- a/cpp/cpp.h +++ b/cpp/cpp.h @@ -142,7 +142,7 @@ void iniths(void); void setobjname(char *); #define rowlen(tokrow) ((tokrow)->lp - (tokrow)->bp) -extern char *outp; +extern char *outptr; extern Token nltoken; extern Source *cursource; extern char *curtime; diff --git a/cpp/include.c b/cpp/include.c index 3bae83f1..924fd9b2 100755 --- a/cpp/include.c +++ b/cpp/include.c @@ -91,7 +91,7 @@ genline(void) static Tokenrow tr = { &ta, &ta, &ta+1, 1 }; uchar *p; - ta.t = p = (uchar*)outp; + ta.t = p = (uchar*)outptr; strcpy((char*)p, "#line "); p += sizeof("#line ")-1; p = (uchar*)outnum((char*)p, cursource->line); @@ -99,8 +99,8 @@ genline(void) strcpy((char*)p, cursource->filename); p += strlen((char*)p); *p++ = '"'; *p++ = '\n'; - ta.len = (char*)p-outp; - outp = (char*)p; + ta.len = (char*)p-outptr; + outptr = (char*)p; tr.tp = tr.bp; puttokens(&tr); } diff --git a/cpp/macro.c b/cpp/macro.c index 78e0e63c..fc707237 100755 --- a/cpp/macro.c +++ b/cpp/macro.c @@ -472,10 +472,10 @@ builtin(Tokenrow *trp, int biname) /* most are strings */ tp->type = STRING; if (tp->wslen) { - *outp++ = ' '; + *outptr++ = ' '; tp->wslen = 1; } - op = outp; + op = outptr; *op++ = '"'; switch (biname) { @@ -510,7 +510,7 @@ builtin(Tokenrow *trp, int biname) } if (tp->type==STRING) *op++ = '"'; - tp->t = (uchar*)outp; - tp->len = op - outp; - outp = op; + tp->t = (uchar*)outptr; + tp->len = op - outptr; + outptr = op; }