mirror of
https://github.com/boostorg/optional.git
synced 2025-07-25 10:07:15 +02:00
Fix incorrect code markup in IO operator docs.
The previous IO operator declarations were made up from multiple code phrase markups with line breaks, where the markup was broken and some of the line breaks were not translated propertly into output. Replace this with proper code blocks. This also resolves the QuickBook warning about line breaks potentially producing invalid BoostBook output.
This commit is contained in:
@ -41,10 +41,11 @@ template<class CharType, class CharTrait, class T>
|
||||
|
||||
[#reference_operator_ostream]
|
||||
|
||||
|
||||
`template <class CharType, class CharTrait, class T>` [br]
|
||||
std::basic_ostream<CharType, CharTrait>&` [br]
|
||||
operator<<(std::basic_ostream<CharType, CharTrait>& out, optional<T> const& v);`
|
||||
```
|
||||
template <class CharType, class CharTrait, class T>
|
||||
std::basic_ostream<CharType, CharTrait>&
|
||||
operator<<(std::basic_ostream<CharType, CharTrait>& out, optional<T> const& v);
|
||||
```
|
||||
|
||||
* [*Effect:] Outputs an implementation-defined string. The output contains the information about whether the optional object contains a value or not. If `v` contains a value, the output contains result of calling `out << *v`.
|
||||
* [*Returns:] `out`.
|
||||
@ -52,9 +53,11 @@ template<class CharType, class CharTrait, class T>
|
||||
__SPACE__
|
||||
[#reference_operator_ostream_none]
|
||||
|
||||
`template <class CharType, class CharTrait, class T>` [br]
|
||||
std::basic_ostream<CharType, CharTrait>&` [br]
|
||||
operator<<(std::basic_ostream<CharType, CharTrait>& out, none_t);`
|
||||
```
|
||||
template <class CharType, class CharTrait, class T>
|
||||
std::basic_ostream<CharType, CharTrait>&
|
||||
operator<<(std::basic_ostream<CharType, CharTrait>& out, none_t);
|
||||
```
|
||||
|
||||
* [*Effect:] Outputs an implementation-defined string.
|
||||
* [*Returns:] `out`.
|
||||
@ -62,9 +65,11 @@ __SPACE__
|
||||
__SPACE__
|
||||
[#reference_operator_istream]
|
||||
|
||||
`template <class CharType, class CharTrait, class T>` [br]
|
||||
std::basic_ostream<CharType, CharTrait>&` [br]
|
||||
operator>>(std::basic_istream<CharType, CharTrait>& in, optional<T>& v);`
|
||||
```
|
||||
template <class CharType, class CharTrait, class T>
|
||||
std::basic_ostream<CharType, CharTrait>&
|
||||
operator>>(std::basic_istream<CharType, CharTrait>& in, optional<T>& v);
|
||||
```
|
||||
|
||||
* [*Requires:] `T` is __STD_DEFAULT_CONSTRUCTIBLE__ and __MOVE_CONSTRUCTIBLE__.
|
||||
* [*Effect:] Reads the value of optional object from `in`. If the string representation indicates that the optional object should contain a value, `v` contains a value and its contained value is obtained as if by default-constructing an object `o` of type `T` and then calling `in >> o`; otherwise `v` does not contain a value, and the previously contained value (if any) has been destroyed.
|
||||
|
Reference in New Issue
Block a user