From Jason Turner

[syncstream.syncbuf.cons]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpzzei2vlh/{from.md → to.md} +40 -0
tmp/tmpzzei2vlh/{from.md → to.md} RENAMED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #### Construction and destruction <a id="syncstream.syncbuf.cons">[[syncstream.syncbuf.cons]]</a>
2
+
3
+ ``` cpp
4
+ basic_syncbuf(streambuf_type* obuf, const Allocator& allocator);
5
+ ```
6
+
7
+ *Effects:* Sets `wrapped` to `obuf`.
8
+
9
+ *Remarks:* A copy of `allocator` is used to allocate memory for internal
10
+ buffers holding the associated output.
11
+
12
+ *Throws:* Nothing unless an exception is thrown by the construction of a
13
+ mutex or by memory allocation.
14
+
15
+ *Ensures:* `get_wrapped() == obuf` and `get_allocator() == allocator`
16
+ are `true`.
17
+
18
+ ``` cpp
19
+ basic_syncbuf(basic_syncbuf&& other);
20
+ ```
21
+
22
+ *Ensures:* The value returned by `this->get_wrapped()` is the value
23
+ returned by `other.get_wrapped()` prior to calling this constructor.
24
+ Output stored in `other` prior to calling this constructor will be
25
+ stored in `*this` afterwards.
26
+ `other.rdbuf()->pbase() == other.rdbuf()->pptr()` and
27
+ `other.get_wrapped() == nullptr` are `true`.
28
+
29
+ *Remarks:* This constructor disassociates `other` from its wrapped
30
+ stream buffer, ensuring destruction of `other` produces no output.
31
+
32
+ ``` cpp
33
+ ~basic_syncbuf();
34
+ ```
35
+
36
+ *Effects:* Calls `emit()`.
37
+
38
+ *Throws:* Nothing. If an exception is thrown from `emit()`, the
39
+ destructor catches and ignores that exception.
40
+