Make unity.c compatible with c90

Avoid declaring the loop variable inside the for statement to keep
compatibility with c90:

unity.c:1408: error: for' loop initial declaration used outside C99 mode
This commit is contained in:
Luca Boccassi
2019-01-24 21:44:34 +00:00
parent a284984365
commit 5074a3d8b2

View File

@@ -1523,8 +1523,9 @@ int UnityParseOptions(int argc, char** argv)
{
UnityOptionIncludeNamed = NULL;
UnityOptionExcludeNamed = NULL;
int i;
for (int i = 1; i < argc; i++)
for (i = 1; i < argc; i++)
{
if (argv[i][0] == '-')
{