std::experimental::bad_optional_access(3cxx)

std::experimental::bad_optional_access3cxx

Exception class thrown when a disengaged optional object is dereferenced.

Usage

#include <optional>

Inherits std::logic_error.

Public Member Functions

bad_optional_access (const char *__arg)
virtual const char * what () const noexcept

Detailed Description

Exception class thrown when a disengaged optional object is dereferenced.

Member Function Documentation

virtual const char * std::logic_error::what () const [virtual], [noexcept], [inherited]

Returns a C-style character string describing the general cause of the current error (the same string passed to the ctor).

Reimplemented from std::exception.

Reimplemented in std::future_error.

Releases

5 releases since Debian 9 (Stretch); the text changed 4 times.

  1. 9
  2. 10
  3. 11
  4. 12
  5. 13

Author

Generated automatically by Doxygen for libstdc++ from the source code.

From libstdc++-12-doc 12.4.0-5 in Debian 13 (Trixie). Also shipped by libstdc++-13-doc, libstdc++-14-doc. Parsed by carta from the page's man source.