We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 826ebd9 commit a4375efCopy full SHA for a4375ef
1 file changed
test/testtokenize.cpp
@@ -2387,6 +2387,19 @@ class TestTokenizer : public TestFixture {
2387
ASSERT_EQUALS(expected, tokenizeAndStringify(code));
2388
}
2389
2390
+ void vardecl_template_3() {
2391
+ const char code[] = "template <class T>\n" // #14909
2392
+ "void f(T x) {\n"
2393
+ " const auto y = h<T, x.size()>;\n"
2394
+ "}";
2395
+ const char expected[] = "template < class T >\n"
2396
+ "void f ( T x ) {\n"
2397
+ "const auto y = h < T , x . size ( ) > ;\n"
2398
2399
+ ASSERT_EQUALS(expected, tokenizeAndStringify(code));
2400
+ ASSERT_EQUALS("[test.cpp:3:11]: (debug) auto token with no type. [autoNoType]\n", errout_str());
2401
+ }
2402
+
2403
void vardecl_union() {
2404
// ticket #1976
2405
const char code1[] = "class Fred { public: union { int a ; int b ; } ; } ;";
0 commit comments