diff options
author | theraven <theraven@FreeBSD.org> | 2012-03-14 00:09:36 +0000 |
---|---|---|
committer | theraven <theraven@FreeBSD.org> | 2012-03-14 00:09:36 +0000 |
commit | 7bd22d0949674b61e2c1a97cbb6caeeb5ab7fd19 (patch) | |
tree | 077f044b08d256dd8348f977fe56d18c08fccd78 /contrib/libc++/src/hash.cpp | |
parent | d83b894ff4280333de5ef40496cfd061b515ba54 (diff) | |
parent | baa75b9984d33ea49ffb76a73507b64d879166cc (diff) | |
download | FreeBSD-src-7bd22d0949674b61e2c1a97cbb6caeeb5ab7fd19.zip FreeBSD-src-7bd22d0949674b61e2c1a97cbb6caeeb5ab7fd19.tar.gz |
Import new versions of libcxxrt and libc++.
Please tests any C++ code you care about with -stdlib=libc++!
Approved by: dim (mentor)
Diffstat (limited to 'contrib/libc++/src/hash.cpp')
-rw-r--r-- | contrib/libc++/src/hash.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/contrib/libc++/src/hash.cpp b/contrib/libc++/src/hash.cpp index 728b9bd..6f30d5a 100644 --- a/contrib/libc++/src/hash.cpp +++ b/contrib/libc++/src/hash.cpp @@ -181,7 +181,8 @@ __next_prime(size_t n) // Select first potential prime >= n // Known a-priori n >= L size_t k0 = n / L; - size_t in = std::lower_bound(indices, indices + M, n - k0 * L) - indices; + size_t in = static_cast<size_t>(std::lower_bound(indices, indices + M, n - k0 * L) + - indices); n = L * k0 + indices[in]; while (true) { |