Don't rely on C99 for loop initializers in test case

This allows compilation of the test case with GCC 4.8.

llvm-svn: 187057
This commit is contained in:
Stefanus Du Toit 2013-07-24 17:48:04 +00:00
parent b8f3590357
commit 2e36aaeaa7
1 changed files with 4 additions and 2 deletions

View File

@ -17,7 +17,8 @@ int
call_me (int some_value)
{
int ret_val = 0;
for (int i = 0; i < some_value; i++)
int i;
for (i = 0; i < some_value; i++)
{
int result = 0;
if (i%2 == 0)
@ -37,7 +38,8 @@ int
call_me_nosig (int some_value)
{
int ret_val = 0;
for (int i = 0; i < some_value; i++)
int i;
for (i = 0; i < some_value; i++)
weird_value += i % 4;
nosig_no += some_value;