[PATCH] D29899: [clang-tidy] Add support for NOLINTNEXTLINE.
Alexander Kornienko via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 14 04:18:30 PST 2017
alexfh accepted this revision.
alexfh added a comment.
This revision is now accepted and ready to land.
Awesome! LG with one nit.
================
Comment at: clang-tidy/ClangTidyDiagnosticConsumer.cpp:300
+ // Now skip any newlines.
+ // FIXME: We want to skip over exactly one line, not an arbitrary number.
+ while (P != BufBegin && (*P == '\r' || *P == '\n'))
----------------
Is it difficult to address right away?
I also suppose (https://en.wikipedia.org/wiki/Newline#Representations) that we only care about CR+LF or LF line endings, so just looking at LFs seems more than enough (and will make code slightly simpler). This is the approach we took in many places in clang-format.
https://reviews.llvm.org/D29899
More information about the cfe-commits
mailing list