##### cppreference.com

##### Search

Create account

##### Namespaces

- Page
- Discussion

##### Variants

##### Views

- View
- Edit
- History

##### Actions

# std::ostreambuf_iterator::operator=

From cppreference.com
< cpp‎ | iterator‎ | ostreambuf iterator

ostreambuf_iterator& operator=( CharT c ) |  |

If failed() returns true, inserts the character `c` into the associated stream buffer by calling pbuf->sputc(c), where `pbuf` is the private member of type `streambuf_type*`. Otherwise, does nothing.

If the call to pbuf->sputc(c) returns Traits::eof, sets the failed() flag to true.

### [edit] Parameters

c | - | the character to insert

### [edit] Return value

*this

### [edit] Example

| This section is incomplete

### [edit] See also

sputc | writes one character to the put area and advances the next pointer (public member function of `std::basic_streambuf`) [edit]

Retrieved from "http://en.cppreference.com/mwiki/index.php?title=cpp/iterator/ostreambuf_iterator/operator%3D&oldid=64301"
Category:

- Todo without reason