Skip to content

Commit 07368d6

Browse files
Add test for #12136 (#8921)
1 parent 5f9b5cc commit 07368d6

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

‎test/testother.cpp‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2773,6 +2773,18 @@ class TestOther : public TestFixture {
27732773
"void S::func(S::F f) {}\n");
27742774
ASSERT_EQUALS("", errout_str());
27752775

2776+
check("bool f(std::vector<std::vector<int>> v) {\n" // #12136
2777+
" if (v.size() != 10U)\n"
2778+
" return false;\n"
2779+
" for (auto it = v.begin(); it != v.end(); ++it) {\n"
2780+
" if (it->size() < 9U)\n"
2781+
" return false;\n"
2782+
" it->erase(it->begin(), it->begin() + 9U);\n"
2783+
" }\n"
2784+
" return true;\n"
2785+
"}\n");
2786+
ASSERT_EQUALS("", errout_str());
2787+
27762788
/*const*/ Settings settingsWin64 = settingsBuilder().platform(Platform::Type::Win64).build();
27772789
check("using ui64 = unsigned __int64;\n"
27782790
"ui64 Test(ui64 one, ui64 two) { return one + two; }\n",

0 commit comments

Comments
 (0)