This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: cpplib: double speed of comment skipping


Zack Weinberg wrote:- > > + else if (c == '/') > > + { > > + /* Avoid false positives for the comment's initial '*'. */ > > + if (cur[-2] == '*' && cur - 2 >= CPP_BUFFER (pfile)->cur) > > + goto out; > > I believe you can avoid the extra check by changing the FORWARD(1) at > the beginning, to FORWARD(2). I'll test the patch with that change > made. Hmmm. What if the character after the "/*" is a '\n' or '\r'? Neil.
Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]