//===----------------------------------------------------------------------===// // // The LLVM Compiler Infrastructure // // This file is dual licensed under the MIT and the University of Illinois Open // Source Licenses. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// // // template // basic_string_view(const basic_string<_CharT, _Traits, Allocator>& _str) noexcept #include #include #include struct dummy_char_traits : public std::char_traits {}; int main () { using string_view = std::experimental::basic_string_view; using string = std:: basic_string ; { string s{"QBCDE"}; string_view sv1 ( s ); assert ( sv1.size() == s.size()); assert ( sv1.data() == s.data()); } }