Skip to content

Commit 3435f2d

Browse files
Update teststl.cpp
1 parent 0089f5a commit 3435f2d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

test/teststl.cpp

+8
Original file line numberDiff line numberDiff line change
@@ -5430,6 +5430,14 @@ class TestStl : public TestFixture {
54305430
" return sum;\n"
54315431
"}\n");
54325432
ASSERT_EQUALS("", errout_str());
5433+
5434+
check("int f(const std::vector<int>& v) {\n" // #12900
5435+
" int x{};\n"
5436+
" for (const auto i : v)\n"
5437+
" x = dostuff(i);\n"
5438+
" return x;\n"
5439+
"}\n");
5440+
ASSERT_EQUALS("", errout_str());
54335441
}
54345442

54355443
void loopAlgoContainerInsert() {

0 commit comments

Comments
 (0)