int AccFileSpecifier = 0; /* return filespecifier <...> */
int EoiForNewline = 0; /* return EOI upon encountering newline */
int File_Inserted = 0; /* a file has just been inserted */
+#ifdef LINT
+extern int lint_skip_comment;
+#endif
#define MAX_LL_DEPTH 2
NoUnstack++;
LoadChar(c);
#ifdef LINT
- lint_start_comment();
- lint_comment_char(c);
+ if (! lint_skip_comment) {
+ lint_start_comment();
+ lint_comment_char(c);
+ }
#endif /* LINT */
do {
while (c != '*') {
if (c == EOI) {
NoUnstack--;
#ifdef LINT
- lint_end_comment();
+ if (! lint_skip_comment) lint_end_comment();
#endif /* LINT */
return;
}
LoadChar(c);
#ifdef LINT
- lint_comment_char(c);
+ if (! lint_skip_comment) lint_comment_char(c);
#endif /* LINT */
} /* last Character seen was '*' */
LoadChar(c);
#ifdef LINT
- lint_comment_char(c);
+ if (! lint_skip_comment) lint_comment_char(c);
#endif /* LINT */
} while (c != '/');
#ifdef LINT
- lint_end_comment();
+ if (! lint_skip_comment) lint_end_comment();
#endif /* LINT */
NoUnstack--;
}
#include "idf.h"
#include "input.h"
#include "nopp.h"
+#include "lint.h"
#ifndef NOPP
#include "ifdepth.h"
SkipEscNewline = 0;
}
+#ifdef LINT
+int lint_skip_comment;
+#endif
+
PRIVATE
skip_block(to_endif)
{
register int skiplevel = nestlevel; /* current nesting level */
struct token tk;
+#ifdef LINT
+ lint_skip_comment++;
+#endif
NoUnstack++;
for (;;) {
LoadChar(ch); /* read first character after newline */
if (ch != '#') {
if (ch == EOI) {
NoUnstack--;
+#ifdef LINT
+ lint_skip_comment--;
+#endif
return;
}
SkipRestOfLine();
push_if();
if (ifexpr()) {
NoUnstack--;
+#ifdef LINT
+ lint_skip_comment--;
+#endif
return;
}
}
++(ifstack[nestlevel]);
if (nestlevel == skiplevel) {
NoUnstack--;
+#ifdef LINT
+ lint_skip_comment--;
+#endif
return;
}
}
if (nestlevel == skiplevel) {
nestlevel--;
NoUnstack--;
+#ifdef LINT
+ lint_skip_comment--;
+#endif
return;
}
nestlevel--;