Silence -Wint-to-void-pointer-cast warning in test.

llvm-svn: 185756
This commit is contained in:
Howard Hinnant 2013-07-06 14:41:36 +00:00
parent c7332b2796
commit 5e00063b86
1 changed files with 3 additions and 2 deletions

View File

@ -16,6 +16,7 @@
#include <ios>
#include <string>
#include <cassert>
#include <cstdint>
class test
: public std::ios
@ -31,12 +32,12 @@ int main()
{
test t;
std::ios_base& b = t;
for (int i = 0; i < 10000; ++i)
for (std::intptr_t i = 0; i < 10000; ++i)
{
assert(b.pword(i) == 0);
b.pword(i) = (void*)i;
assert(b.pword(i) == (void*)i);
for (int j = 0; j <= i; ++j)
for (std::intptr_t j = 0; j <= i; ++j)
assert(b.pword(j) == (void*)j);
}
}