Fix compiler warnings from int/size_t mismatches
Cast size_t return from std::vector explicitly to int to silence compiler warnings. Change-Id: I0c425b3cec7feec0712e1173ab7e60b28695d6d7 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
This commit is contained in:
parent
bbc385150f
commit
0a1c0accf0
@ -94,7 +94,7 @@ int main(int argc, char** argv)
|
||||
/* Run with no special arguments. */
|
||||
{
|
||||
tst_BenchlibOptions test;
|
||||
ret += QTest::qExec(&test, args.size(), const_cast<char**>(&args[0]));
|
||||
ret += QTest::qExec(&test, int(args.size()), const_cast<char**>(&args[0]));
|
||||
}
|
||||
|
||||
/* Run with an exact number of iterations. */
|
||||
@ -103,7 +103,7 @@ int main(int argc, char** argv)
|
||||
extraArgs.push_back("-iterations");
|
||||
extraArgs.push_back("15");
|
||||
tst_BenchlibFifteenIterations test;
|
||||
ret += QTest::qExec(&test, extraArgs.size(), const_cast<char**>(&extraArgs[0]));
|
||||
ret += QTest::qExec(&test, int(extraArgs.size()), const_cast<char**>(&extraArgs[0]));
|
||||
}
|
||||
|
||||
/*
|
||||
@ -114,7 +114,7 @@ int main(int argc, char** argv)
|
||||
extraArgs.push_back("-minimumvalue");
|
||||
extraArgs.push_back("100");
|
||||
tst_BenchlibOneHundredMinimum test;
|
||||
ret += QTest::qExec(&test, extraArgs.size(), const_cast<char**>(&extraArgs[0]));
|
||||
ret += QTest::qExec(&test, int(extraArgs.size()), const_cast<char**>(&extraArgs[0]));
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
@ -69,7 +69,7 @@ int main(int argc, char *argv[])
|
||||
args.push_back("fiveTablePasses");
|
||||
args.push_back("fiveTablePasses:fiveTablePasses_data1");
|
||||
args.push_back("-v2");
|
||||
argc = args.size();
|
||||
argc = int(args.size());
|
||||
argv = const_cast<char**>(&args[0]);
|
||||
|
||||
QTEST_MAIN_IMPL(tst_DataTable)
|
||||
|
Loading…
Reference in New Issue
Block a user