Always turn on the -+ flag in cpp
C99 comments have been the default in compilers for something like 20 years now. This means we don't need to remember to turn it on when porting software, and gets rid of cryptic errors about unterminated character constants when someone writes something like: // Didn't need to... We still accept the flag to avoid breaking mkfiles, but we do nothing with it. This also removes the documentation, since the option does nothing now.
This commit is contained in:
parent
ff344562db
commit
94fb8869df
7 changed files with 2 additions and 21 deletions
|
@ -67,9 +67,6 @@ Do not insert
|
|||
.RB `` #line ''
|
||||
directives into the output.
|
||||
.TP
|
||||
.B -+
|
||||
Understand C++ comments.
|
||||
.TP
|
||||
.B -.
|
||||
Inhibit include search in the source's directory.
|
||||
.TP
|
||||
|
|
|
@ -25,11 +25,6 @@ The object files are then loaded using one of the loaders described in
|
|||
.IR 2l (1).
|
||||
The options are:
|
||||
.TP \w'\fL-D\ \fIname=def\ 'u
|
||||
.B "-+
|
||||
Accept C++
|
||||
.B //
|
||||
comments.
|
||||
.TP
|
||||
.BI -o " out"
|
||||
Place loader output in file
|
||||
.I out
|
||||
|
|
|
@ -28,7 +28,6 @@ main(int argc, char **argv)
|
|||
maketokenrow(3, &tr);
|
||||
expandlex();
|
||||
setup(argc, argv);
|
||||
fixlex();
|
||||
iniths();
|
||||
genline();
|
||||
process(&tr);
|
||||
|
|
|
@ -86,7 +86,6 @@ extern unsigned long namebit[077+1];
|
|||
enum errtype { WARNING, ERROR, FATAL };
|
||||
|
||||
void expandlex(void);
|
||||
void fixlex(void);
|
||||
void setup(int, char **);
|
||||
#define gettokens cpp_gettokens
|
||||
int gettokens(Tokenrow *, int);
|
||||
|
|
|
@ -285,14 +285,6 @@ expandlex(void)
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
fixlex(void)
|
||||
{
|
||||
/* do C++ comments? */
|
||||
if (Cplusplus==0)
|
||||
bigfsm['/'][COM1] = bigfsm['x'][COM1];
|
||||
}
|
||||
|
||||
/*
|
||||
* fill in a row of tokens from input, terminated by NL or END
|
||||
* First token is put at trp->lp.
|
||||
|
|
|
@ -8,7 +8,6 @@ extern char *optarg;
|
|||
extern int optind;
|
||||
int verbose;
|
||||
int Mflag;
|
||||
int Cplusplus;
|
||||
int nolineinfo;
|
||||
Nlist *kwdefined;
|
||||
char wd[128];
|
||||
|
@ -142,7 +141,7 @@ setup(int argc, char **argv)
|
|||
verbose++;
|
||||
break;
|
||||
case '+':
|
||||
Cplusplus++;
|
||||
/* Ignored for compatibility */
|
||||
break;
|
||||
case 'i':
|
||||
debuginclude++;
|
||||
|
|
|
@ -65,7 +65,7 @@ main(int argc, char *argv[])
|
|||
while(argc > 0) {
|
||||
ARGBEGIN {
|
||||
case '+':
|
||||
append(&cpp, smprint("-%c", ARGC()));
|
||||
/* No-op for compatibility */
|
||||
break;
|
||||
case 'c':
|
||||
cflag = 1;
|
||||
|
|
Loading…
Reference in a new issue