Uninitialized variables; fix syntax errors in test cases

This commit is contained in:
Daniel Marjamäki 2021-05-21 15:30:52 +02:00
parent 1e6a574cff
commit 2d3d7db730
1 changed files with 2 additions and 2 deletions

View File

@ -1376,7 +1376,7 @@ private:
" if (true) {;}\n" " if (true) {;}\n"
" else\n" " else\n"
" {\n" " {\n"
" return 1;\n" " return;\n"
" }\n" " }\n"
" *p = 7;\n" // << " *p = 7;\n" // <<
" p = new int(9);\n" " p = new int(9);\n"
@ -1490,7 +1490,7 @@ private:
// arrays.. // arrays..
void uninitvar_arrays() { void uninitvar_arrays() {
checkUninitVar("int f()\n" checkUninitVar("void f()\n"
"{\n" "{\n"
" char a[10];\n" " char a[10];\n"
" a[a[0]] = 0;\n" " a[a[0]] = 0;\n"