MCPcopy Create free account
hub / github.com/pybind/pybind11 / overflow

Method overflow

include/pybind11/iostream.h:47–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45 object pyflush;
46
47 int overflow(int c) override {
48 if (!traits_type::eq_int_type(c, traits_type::eof())) {
49 *pptr() = traits_type::to_char_type(c);
50 pbump(1);
51 }
52 return sync() == 0 ? traits_type::not_eof(c) : traits_type::eof();
53 }
54
55 // Computes how many bytes at the end of the buffer are part of an
56 // incomplete sequence of UTF-8 bytes.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected