Files
2025-10-25 03:02:53 +03:00

1.3 KiB
Raw Permalink Blame History

[string.view.general]

27 Strings library [strings]

27.3 String view classes [string.view]

27.3.1 General [string.view.general]

1

#

The class template basic_string_view describes an object that can refer to a constant contiguous sequence of char-like ([strings.general]) objects with the first element of the sequence at position zero.

In the rest of [string.view], the type of the char-like objects held in a basic_string_view object is designated by charT.

2

#

[Note 1:

The library provides implicit conversions from const charT* and std::basic_string<charT, ...> to std::basic_string_view<charT, ...> so that user code can accept just std::basic_string_view as a non-templated parameter wherever a sequence of characters is expected.

User-defined types can define their own implicit conversions to std::basic_string_view in order to interoperate with these functions.

— end note]