tmp/tmphvq16x69/{from.md → to.md}
RENAMED
|
@@ -4,31 +4,32 @@
|
|
| 4 |
namespace std {
|
| 5 |
template <class charT, class traits = char_traits<charT>,
|
| 6 |
class Allocator = allocator<charT>>
|
| 7 |
class basic_istringstream : public basic_istream<charT, traits> {
|
| 8 |
public:
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
|
| 16 |
-
// [istringstream.cons]
|
| 17 |
-
explicit basic_istringstream(
|
|
|
|
| 18 |
explicit basic_istringstream(
|
| 19 |
const basic_string<charT, traits, Allocator>& str,
|
| 20 |
ios_base::openmode which = ios_base::in);
|
| 21 |
basic_istringstream(const basic_istringstream& rhs) = delete;
|
| 22 |
basic_istringstream(basic_istringstream&& rhs);
|
| 23 |
|
| 24 |
-
// [istringstream.assign]
|
| 25 |
basic_istringstream& operator=(const basic_istringstream& rhs) = delete;
|
| 26 |
basic_istringstream& operator=(basic_istringstream&& rhs);
|
| 27 |
void swap(basic_istringstream& rhs);
|
| 28 |
|
| 29 |
-
// [istringstream.members]
|
| 30 |
basic_stringbuf<charT, traits, Allocator>* rdbuf() const;
|
| 31 |
|
| 32 |
basic_string<charT, traits, Allocator> str() const;
|
| 33 |
void str(const basic_string<charT, traits, Allocator>& s);
|
| 34 |
private:
|
|
@@ -75,12 +76,12 @@ explicit basic_istringstream(
|
|
| 75 |
basic_istringstream(basic_istringstream&& rhs);
|
| 76 |
```
|
| 77 |
|
| 78 |
*Effects:* Move constructs from the rvalue `rhs`. This is accomplished
|
| 79 |
by move constructing the base class, and the contained
|
| 80 |
-
`basic_stringbuf`. Next `basic_istream<charT,traits>::set_rdbuf(&sb)`
|
| 81 |
-
called to install the contained `basic_stringbuf`.
|
| 82 |
|
| 83 |
#### Assign and swap <a id="istringstream.assign">[[istringstream.assign]]</a>
|
| 84 |
|
| 85 |
``` cpp
|
| 86 |
basic_istringstream& operator=(basic_istringstream&& rhs);
|
|
@@ -102,19 +103,20 @@ void swap(basic_istringstream& rhs);
|
|
| 102 |
template <class charT, class traits, class Allocator>
|
| 103 |
void swap(basic_istringstream<charT, traits, Allocator>& x,
|
| 104 |
basic_istringstream<charT, traits, Allocator>& y);
|
| 105 |
```
|
| 106 |
|
| 107 |
-
*Effects:* `x.swap(y)`.
|
| 108 |
|
| 109 |
#### Member functions <a id="istringstream.members">[[istringstream.members]]</a>
|
| 110 |
|
| 111 |
``` cpp
|
| 112 |
basic_stringbuf<charT, traits, Allocator>* rdbuf() const;
|
| 113 |
```
|
| 114 |
|
| 115 |
-
*Returns:*
|
|
|
|
| 116 |
|
| 117 |
``` cpp
|
| 118 |
basic_string<charT, traits, Allocator> str() const;
|
| 119 |
```
|
| 120 |
|
|
|
|
| 4 |
namespace std {
|
| 5 |
template <class charT, class traits = char_traits<charT>,
|
| 6 |
class Allocator = allocator<charT>>
|
| 7 |
class basic_istringstream : public basic_istream<charT, traits> {
|
| 8 |
public:
|
| 9 |
+
using char_type = charT;
|
| 10 |
+
using int_type = typename traits::int_type;
|
| 11 |
+
using pos_type = typename traits::pos_type;
|
| 12 |
+
using off_type = typename traits::off_type;
|
| 13 |
+
using traits_type = traits;
|
| 14 |
+
using allocator_type = Allocator;
|
| 15 |
|
| 16 |
+
// [istringstream.cons], constructors
|
| 17 |
+
explicit basic_istringstream(
|
| 18 |
+
ios_base::openmode which = ios_base::in);
|
| 19 |
explicit basic_istringstream(
|
| 20 |
const basic_string<charT, traits, Allocator>& str,
|
| 21 |
ios_base::openmode which = ios_base::in);
|
| 22 |
basic_istringstream(const basic_istringstream& rhs) = delete;
|
| 23 |
basic_istringstream(basic_istringstream&& rhs);
|
| 24 |
|
| 25 |
+
// [istringstream.assign], assign and swap
|
| 26 |
basic_istringstream& operator=(const basic_istringstream& rhs) = delete;
|
| 27 |
basic_istringstream& operator=(basic_istringstream&& rhs);
|
| 28 |
void swap(basic_istringstream& rhs);
|
| 29 |
|
| 30 |
+
// [istringstream.members], members
|
| 31 |
basic_stringbuf<charT, traits, Allocator>* rdbuf() const;
|
| 32 |
|
| 33 |
basic_string<charT, traits, Allocator> str() const;
|
| 34 |
void str(const basic_string<charT, traits, Allocator>& s);
|
| 35 |
private:
|
|
|
|
| 76 |
basic_istringstream(basic_istringstream&& rhs);
|
| 77 |
```
|
| 78 |
|
| 79 |
*Effects:* Move constructs from the rvalue `rhs`. This is accomplished
|
| 80 |
by move constructing the base class, and the contained
|
| 81 |
+
`basic_stringbuf`. Next `basic_istream<charT, traits>::set_rdbuf(&sb)`
|
| 82 |
+
is called to install the contained `basic_stringbuf`.
|
| 83 |
|
| 84 |
#### Assign and swap <a id="istringstream.assign">[[istringstream.assign]]</a>
|
| 85 |
|
| 86 |
``` cpp
|
| 87 |
basic_istringstream& operator=(basic_istringstream&& rhs);
|
|
|
|
| 103 |
template <class charT, class traits, class Allocator>
|
| 104 |
void swap(basic_istringstream<charT, traits, Allocator>& x,
|
| 105 |
basic_istringstream<charT, traits, Allocator>& y);
|
| 106 |
```
|
| 107 |
|
| 108 |
+
*Effects:* As if by `x.swap(y)`.
|
| 109 |
|
| 110 |
#### Member functions <a id="istringstream.members">[[istringstream.members]]</a>
|
| 111 |
|
| 112 |
``` cpp
|
| 113 |
basic_stringbuf<charT, traits, Allocator>* rdbuf() const;
|
| 114 |
```
|
| 115 |
|
| 116 |
+
*Returns:*
|
| 117 |
+
`const_cast<basic_stringbuf<charT, traits, Allocator>*>(&sb)`.
|
| 118 |
|
| 119 |
``` cpp
|
| 120 |
basic_string<charT, traits, Allocator> str() const;
|
| 121 |
```
|
| 122 |
|