mirror of
https://gitlab.com/fbb-git/cppannotations
synced 2024-11-16 07:48:44 +01:00
cosmetics
This commit is contained in:
parent
3a9846e2aa
commit
664b795b9b
1 changed files with 9 additions and 9 deletions
|
@ -46,23 +46,23 @@ tt(DataType) value, then its tt(bool) value is tt(false).
|
|||
|
||||
The class tt(std::optional) offers the following facilities:
|
||||
itemization(
|
||||
it() Constructors:nl()
|
||||
it() Constructors+nl()
|
||||
The default constructor (e.g., tt(std::optional<std::string> opt;))
|
||||
does not contain a value;nl()
|
||||
Copy- and move constructors are available;nl()
|
||||
Objects may be constructed from values that are convertible to the
|
||||
copy- and move constructors are available;nl()
|
||||
objects may be constructed from values that are convertible to the
|
||||
optional's tt(DataType) (e.g., an tt(optional<string>) can be
|
||||
initialized from a NTBS). If the initializing value is an rvalue
|
||||
reference then the tt(DataType) object is move-constructed from the
|
||||
initializing value;
|
||||
|
||||
itt(operator=)nl()
|
||||
The assignment operator can be used to reassign the tt(DataType) values
|
||||
the assignment operator can be used to reassign the tt(DataType) values
|
||||
of tt(optional) objects or to reassign the tt(optional) objects from
|
||||
another tt(optional) object using the same tt(DataType). Copy- and
|
||||
move-assignment operators are available;
|
||||
|
||||
it() Accessors:nl()
|
||||
it() Accessors+nl()
|
||||
tt(explicit operator bool()) and the tt(has_value()) members return
|
||||
tt(true) if the tt(optional) object contains a tt(DataType) value;nl()
|
||||
tt(value(), operator*(),) and tt(operator->()) return references to the
|
||||
|
@ -74,7 +74,7 @@ The class tt(std::optional) offers the following facilities:
|
|||
it() the tt(operator*) and
|
||||
tt(operator->) members act like tt(value), but do not imply
|
||||
that the tt(optional's DataType) member itself is stored as a
|
||||
pointer.
|
||||
pointer;
|
||||
itt(value()) checks whether the tt(optional) object actually
|
||||
contains a tt(DataType) object, and throws a
|
||||
tt(std::bad_optional_access) exception if not.
|
||||
|
@ -85,7 +85,7 @@ The class tt(std::optional) offers the following facilities:
|
|||
tt(DataType{ defaultValue }) if not. Note that tt(DataType) must be
|
||||
constructible from tt(Type);
|
||||
|
||||
it() Modifiers:nl()
|
||||
it() Modifiers+nl()
|
||||
tt(swap(optional<DataType> &other)): swaps the current and other
|
||||
tt(optional) objects' content.nl()
|
||||
tt(reset()): erases the tt(optional's DataType) member. Following
|
||||
|
@ -95,8 +95,8 @@ The class tt(std::optional) offers the following facilities:
|
|||
the second tt(emplace) forwards tt(args) to the initializer_list, and
|
||||
forwards that list to tt(DataType's) constructor;
|
||||
|
||||
it() Comparison operators:nl()
|
||||
All comparison operators (including tt(operator<=>)) are available (if
|
||||
it() Comparison operators+nl()
|
||||
all comparison operators (including tt(operator<=>)) are available (if
|
||||
defined for the tt(optional's DataType)) to compare the tt(DataType)
|
||||
objects of two tt(optional) objects;
|
||||
|
||||
|
|
Loading…
Reference in a new issue