Skip to content

Commit a2dc293

Browse files
committed
add test
1 parent 174a569 commit a2dc293

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

test/testsimplifyusing.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ class TestSimplifyUsing : public TestFixture {
7878
TEST_CASE(simplifyUsing38);
7979
TEST_CASE(simplifyUsing39);
8080
TEST_CASE(simplifyUsing40);
81+
TEST_CASE(simplifyUsing41);
8182

8283
TEST_CASE(simplifyUsing8970);
8384
TEST_CASE(simplifyUsing8971);
@@ -948,6 +949,13 @@ class TestSimplifyUsing : public TestFixture {
948949
ASSERT_EQUALS(expected, tok(code));
949950
}
950951

952+
void simplifyUsing41() {
953+
const char code[] = "using FpHandler = void(*)(const SourceLocation&);\n"
954+
"inline FpHandler AssertImpl::m_fpHandler = nullptr;\n";
955+
const char expected[] = "void ( * AssertImpl :: m_fpHandler ) ( const SourceLocation & ) ; m_fpHandler = nullptr ;";
956+
ASSERT_EQUALS(expected, tok(code));
957+
}
958+
951959
void simplifyUsing8970() {
952960
const char code[] = "using V = std::vector<int>;\n"
953961
"struct A {\n"

0 commit comments

Comments
 (0)