File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4956,12 +4956,20 @@ class TestCondition : public TestFixture {
49564956 " if (42L) {}\n "
49574957 " if (42UL) {}\n "
49584958 " if (42LL) {}\n "
4959+ " if (042) {}\n "
4960+ " if (0x42) {}\n "
4961+ " if (0b101010) {}\n "
4962+ " if (!42) {}\n "
49594963 " }\n " );
49604964 ASSERT_EQUALS (" [test.cpp:2:9]: (style) Condition '42' is always true [knownConditionTrueFalse]\n "
49614965 " [test.cpp:3:9]: (style) Condition '42U' is always true [knownConditionTrueFalse]\n "
49624966 " [test.cpp:4:9]: (style) Condition '42L' is always true [knownConditionTrueFalse]\n "
49634967 " [test.cpp:5:9]: (style) Condition '42UL' is always true [knownConditionTrueFalse]\n "
4964- " [test.cpp:6:9]: (style) Condition '42LL' is always true [knownConditionTrueFalse]\n " ,
4968+ " [test.cpp:6:9]: (style) Condition '42LL' is always true [knownConditionTrueFalse]\n "
4969+ " [test.cpp:7:9]: (style) Condition '042' is always true [knownConditionTrueFalse]\n "
4970+ " [test.cpp:8:9]: (style) Condition '0x42' is always true [knownConditionTrueFalse]\n "
4971+ " [test.cpp:9:9]: (style) Condition '0b101010' is always true [knownConditionTrueFalse]\n "
4972+ " [test.cpp:10:9]: (style) Condition '!42' is always false [knownConditionTrueFalse]\n " ,
49654973 errout_str ());
49664974 }
49674975
You can’t perform that action at this time.
0 commit comments