[ Web Proxy ]
URL:
Viewing: http://ru.cppreference.com/cpp/string/basic_string_view/operator%3D [Back]  [Original]

std::basic_string_view<CharT,Traits>::operator= cppreference.com
cppreference.com

std::basic_string_view<CharT,Traits>::operator=

cppreference.com
<tbody> </tbody>
constexpr basic_string_view& operator=( const basic_string_view& view ) noexcept = default;
( C++17)

view.

Parameters

view

Return value

*this

Complexity

.

#include <iostream>
#include <string_view>
int main()
{
    std::string_view v = "Hello, world";
    v = v.substr(7);
    std::cout << v << '\n';
}

:

world

(C++17)
basic_string_view
(public -) []

Web Proxy Viewer  |  New URL  |  Original Page