[PATCH] D75791: [clang-format] Added new option IndentExternBlock
Marcus Johnson via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Mar 24 18:03:51 PDT 2020
MarcusJohnson91 added inline comments.
================
Comment at: clang/unittests/Format/FormatTest.cpp:31
+class FormatTest
+ : public ::testing::Test { // FormatTest is a Fixture, data is reused
protected:
----------------
MyDeveloperDay wrote:
> is this comment necessary?
Removed the comment, it was just a note to myself that fell through the cracks
================
Comment at: clang/unittests/Format/FormatTest.cpp:2440
TEST_F(FormatTest, FormatsExternC) {
- verifyFormat("extern \"C\" {\nint a;");
- verifyFormat("extern \"C\" {}");
+ verifyFormat("extern \"C\" {\nint a; /*2.1*/");
+ verifyFormat("extern \"C\" { /*2.2*/\n}");
----------------
MyDeveloperDay wrote:
> why are you changing tests? where is the test that shows this works when a comment isn't present?
These test comments were adds solely so I could see which part of the tests we're failing, because there's some repeats and it got confusing. Clang's tests would print the line which included the text, it was basically printf debugging without printf.
There is now just one minor change to the existing tests.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D75791/new/
https://reviews.llvm.org/D75791
More information about the cfe-commits
mailing list