TestClass: Added a testcase where a array member variable is initialized through strcpy

This commit is contained in:
Daniel Marjamäki 2009-08-24 17:15:29 +02:00
parent c581753040
commit 0c479b8c9f
1 changed files with 16 additions and 5 deletions

View File

@ -415,6 +415,17 @@ private:
"};\n"); "};\n");
ASSERT_EQUALS("", errout.str()); ASSERT_EQUALS("", errout.str());
checkUninitVar("class John\n"
"{\n"
"public:\n"
" John() { strcpy(name, ""); }\n"
"\n"
"private:\n"
" char name[255];\n"
"};\n");
TODO_ASSERT_EQUALS("", errout.str());
} }
void uninitVarEnum() void uninitVarEnum()