A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://timsong-cpp.github.io/cppwp/n4659/string.view.access below:

[string.view.access]

24 Strings library [strings] 24.4 String view classes [string.view] 24.4.2 Class template basic_­string_­view [string.view.template] 24.4.2.4 Element access [string.view.access]

constexpr const_reference operator[](size_type pos) const;

[Note: Unlike basic_­string​::​operator[], basic_­string_­view​::​operator[](size()) has undefined behavior instead of returning charT(). end note]

constexpr const_reference at(size_type pos) const;

Throws: out_­of_­range if pos >= size().

constexpr const_reference front() const;

constexpr const_reference back() const;

Returns: data_­[size() - 1].

constexpr const_pointer data() const noexcept;

[Note: Unlike basic_­string​::​data() and string literals, data() may return a pointer to a buffer that is not null-terminated. Therefore it is typically a mistake to pass data() to a function that takes just a const charT* and expects a null-terminated string. end note]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4