Stephan T. Lavavej
|
aec1876601
|
[libcxx] [test] Fix string_view tests.
test/std/strings/string.view/string.view.ops/compare.pointer_size.pass.cpp
Passing -1 to size_t triggers signed/unsigned mismatch warnings because it's
a value-modifying conversion. Add static_cast<size_t> to soothe the compiler.
(This file refers to size_t unqualified.)
test/std/strings/string.view/string.view.ops/substr.pass.cpp
Add <algorithm> for std::min() and <stdexcept> for std::out_of_range.
N4618 21.4.2.4 [string.view.access]/1: "Requires: pos < size()."
/4: "[ Note: Unlike basic_string::operator[], basic_string_view::operator[](size())
has undefined behavior instead of returning charT(). -end note ]"
Fixes D27633.
llvm-svn: 289283
|
2016-12-09 22:35:53 +00:00 |
Marshall Clow
|
f067d20c6d
|
Again, w/o the tabs
llvm-svn: 276273
|
2016-07-21 13:19:36 +00:00 |
Marshall Clow
|
ef68f26b28
|
Another fix to appease the no-exception bots.
llvm-svn: 276272
|
2016-07-21 13:18:50 +00:00 |
Marshall Clow
|
187db16996
|
Fix some string_view tests that were failing when exceptions were disabled. Also comment out a _LIBCPP_ASSERT that gcc4.9 was complaining about. Will revisit that later.
llvm-svn: 276241
|
2016-07-21 06:24:04 +00:00 |
Marshall Clow
|
053d81ceeb
|
Implement std::string_view as described in http://wg21.link/P0254R1. Reviewed as https://reviews.llvm.org/D21459
llvm-svn: 276238
|
2016-07-21 05:31:24 +00:00 |