Skip to content

Commit e7dd72c

Browse files
Update testuninitvar.cpp
1 parent 814f96f commit e7dd72c

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

test/testuninitvar.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7784,6 +7784,13 @@ class TestUninitVar : public TestFixture {
77847784
" *s.p = 0;\n"
77857785
"}\n");
77867786
ASSERT_EQUALS("", errout_str());
7787+
7788+
valueFlowUninit("void f() {\n"
7789+
" int x;\n"
7790+
" std::vector<int*> v{ &x };\n"
7791+
" *v[0] = 0;\n"
7792+
"}\n");
7793+
ASSERT_EQUALS("", errout_str());
77877794
}
77887795

77897796
void valueFlowUninitForLoop()

0 commit comments

Comments
 (0)