mirror of
https://github.com/llvm-mirror/libcxx.git
synced 2025-10-23 18:38:30 +08:00
[libcxx] [test] D27013: Fix MSVC warning C4018 "signed/unsigned mismatch", part 1/12.
Change loop indices from int to std::size_t. Also, include <cstddef> when it wasn't already being included. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@287820 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
|
||||
#include <valarray>
|
||||
#include <cassert>
|
||||
#include <cstddef>
|
||||
|
||||
int main()
|
||||
{
|
||||
@@ -30,7 +31,7 @@ int main()
|
||||
v3 >>= v2;
|
||||
assert(v1.size() == v2.size());
|
||||
assert(v1.size() == v3.size());
|
||||
for (int i = 0; i < v1.size(); ++i)
|
||||
for (std::size_t i = 0; i < v1.size(); ++i)
|
||||
assert(v1[i] == v3[i]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user