diff --git a/test/testgarbage.cpp b/test/testgarbage.cpp index cdf6de51c..a92ed1ff1 100644 --- a/test/testgarbage.cpp +++ b/test/testgarbage.cpp @@ -200,6 +200,8 @@ private: TEST_CASE(garbageCode149); // #7085 TEST_CASE(garbageCode150); // #7089 TEST_CASE(garbageCode151); // #4175 + TEST_CASE(garbageCode152); // travis after 9c7271a5 + TEST_CASE(garbageValueFlow); TEST_CASE(garbageSymbolDatabase); @@ -1204,6 +1206,13 @@ private: "}"); } + void garbageCode152() { // happened in travis, originaly from llvm clang code + const char* code = "template \n" + "static std::string foo(char *Bla) {\n" + " while (Bla[1] && Bla[1] != ',') }\n"; + checkCode(code); + } + void garbageValueFlow() { // #6089 const char* code = "{} int foo(struct, x1, struct x2, x3, int, x5, x6, x7)\n"