Skip to content

Commit e6d84cf

Browse files
committed
tests(other): format with uncrustify
Signed-off-by: Aryan Rahar <aryanrahar1@gmail.com>
1 parent a5af661 commit e6d84cf

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

test/testother.cpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,7 @@ class TestOther : public TestFixture {
231231
TEST_CASE(checkCastIntToCharAndBack); // ticket #160
232232

233233
TEST_CASE(checkCommaSeparatedReturn);
234+
TEST_CASE(commaSeparatedReturn_no_fp);
234235
TEST_CASE(checkPassByReference);
235236

236237
TEST_CASE(checkComparisonFunctionIsAlwaysTrueOrFalse);
@@ -11147,6 +11148,18 @@ class TestOther : public TestFixture {
1114711148
"}", true, false, false);
1114811149
ASSERT_EQUALS("", errout_str());
1114911150
}
11151+
void commaSeparatedReturn_no_fp()
11152+
{
11153+
check(
11154+
"int f(){\n"
11155+
" int a = 0, b = 1;\n"
11156+
" a = (a, b); // comma in assignment, not in return\n"
11157+
" return a; // plain return\n"
11158+
"}\n",
11159+
true, false, false
11160+
);
11161+
ASSERT_EQUALS("", errout_str());
11162+
}
1115011163

1115111164
void checkPassByReference() {
1115211165
// #8570 passByValue when std::move is used

0 commit comments

Comments
 (0)