[PATCH] D70638: [Diagnostic] add a warning which warns about misleading indentation
Tyker via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 29 08:00:33 PST 2019
Tyker updated this revision to Diff 231545.
Tyker added a comment.
I just found out that `Parser::isCXXDeclarationStatement` is does more then just disambiguation it can emit diagnostics. which can cause error on correct code. so we can't use it in this context to disambiguate.
so it is not possible to easily disambiguate between statements and declaration. i changed the warning message to reflect that but the message isn't so good now.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D70638/new/
https://reviews.llvm.org/D70638
Files:
clang/include/clang/Basic/DiagnosticGroups.td
clang/include/clang/Basic/DiagnosticParseKinds.td
clang/include/clang/Lex/Preprocessor.h
clang/include/clang/Parse/Parser.h
clang/lib/Parse/ParseStmt.cpp
clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp
clang/test/Index/pragma-diag-reparse.c
clang/test/Misc/warning-wall.c
clang/test/Preprocessor/pragma_diagnostic_sections.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D70638.231545.patch
Type: text/x-patch
Size: 10044 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191129/aa37bfcc/attachment-0001.bin>
More information about the cfe-commits
mailing list