diff --git a/test/testtokenize.cpp b/test/testtokenize.cpp index d5c770169e4..fbc291d238e 100644 --- a/test/testtokenize.cpp +++ b/test/testtokenize.cpp @@ -5453,6 +5453,19 @@ class TestTokenizer : public TestFixture { ASSERT_EQUALS("void search ( ) ;\nvoid dostuff ( ) { search ( ) ; }", tokenizeAndStringify(code)); } + { + const char code[] = "using namespace std;\n" // #8789 + "void f(int* p, int* q) {\n" + " search(p, q, p);\n" + " search(p, q, p, q);\n" + "}\n"; + ASSERT_EQUALS("void f ( int * p , int * q ) {\n" + "search ( p , q , p ) ;\n" + "std :: search ( p , q , p , q ) ;\n" + "}", + tokenizeAndStringify(code)); + } + { const char code[] = "using namespace std;\n" "void foo() {map(a, b); }\n"; // That's obviously not std::map<>