Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext
basic_static_string::resize (2 of 2 overloads)

Change the size of the string.

Synopsis
BOOST_STATIC_STRING_CPP14_CONSTEXPR void
resize(
    size_type n,
    value_type c);
Description

Resizes the string to contain n characters. If n > size(), copies of c are appended. Otherwise, size() is reduced to n.

Parameters

Name

Description

n

The size to resize the string to.

c

The characters to append if the size increases.

Exceptions

Type

Thrown On

std::out_of_range

n > max_size()


PrevUpHomeNext