From Jason Turner

[ostringstream.general]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmprzlcoctu/{from.md → to.md} +13 -6
tmp/tmprzlcoctu/{from.md → to.md} RENAMED
@@ -1,17 +1,16 @@
1
  #### General <a id="ostringstream.general">[[ostringstream.general]]</a>
2
 
3
  ``` cpp
4
  namespace std {
5
- template<class charT, class traits = char_traits<charT>,
6
- class Allocator = allocator<charT>>
7
  class basic_ostringstream : public basic_ostream<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
  // [ostringstream.cons], constructors
17
  basic_ostringstream() : basic_ostringstream(ios_base::out) {}
@@ -33,10 +32,16 @@ namespace std {
33
  ios_base::openmode which, const Allocator& a);
34
  template<class SAlloc>
35
  explicit basic_ostringstream(
36
  const basic_string<charT, traits, SAlloc>& s,
37
  ios_base::openmode which = ios_base::out);
 
 
 
 
 
 
38
  basic_ostringstream(const basic_ostringstream&) = delete;
39
  basic_ostringstream(basic_ostringstream&& rhs);
40
 
41
  basic_ostringstream& operator=(const basic_ostringstream&) = delete;
42
  basic_ostringstream& operator=(basic_ostringstream&& rhs);
@@ -55,10 +60,12 @@ namespace std {
55
 
56
  void str(const basic_string<charT, traits, Allocator>& s);
57
  template<class SAlloc>
58
  void str(const basic_string<charT, traits, SAlloc>& s);
59
  void str(basic_string<charT, traits, Allocator>&& s);
 
 
60
 
61
  private:
62
  basic_stringbuf<charT, traits, Allocator> sb; // exposition only
63
  };
64
  }
@@ -67,7 +74,7 @@ namespace std {
67
  The class `basic_ostringstream<charT, traits, Allocator>` supports
68
  writing objects of class `basic_string<{}charT, traits, Allocator>`. It
69
  uses a `basic_stringbuf` object to control the associated storage. For
70
  the sake of exposition, the maintained data is presented here as:
71
 
72
- - `sb`, the `stringbuf` object.
73
 
 
1
  #### General <a id="ostringstream.general">[[ostringstream.general]]</a>
2
 
3
  ``` cpp
4
  namespace std {
5
+ template<class charT, class traits = char_traits<charT>, class Allocator = allocator<charT>>
 
6
  class basic_ostringstream : public basic_ostream<charT, traits> {
7
  public:
8
  using char_type = charT;
9
+ using int_type = traits::int_type;
10
+ using pos_type = traits::pos_type;
11
+ using off_type = traits::off_type;
12
  using traits_type = traits;
13
  using allocator_type = Allocator;
14
 
15
  // [ostringstream.cons], constructors
16
  basic_ostringstream() : basic_ostringstream(ios_base::out) {}
 
32
  ios_base::openmode which, const Allocator& a);
33
  template<class SAlloc>
34
  explicit basic_ostringstream(
35
  const basic_string<charT, traits, SAlloc>& s,
36
  ios_base::openmode which = ios_base::out);
37
+ template<class T>
38
+ explicit basic_ostringstream(const T& t, ios_base::openmode which = ios_base::out);
39
+ template<class T>
40
+ basic_ostringstream(const T& t, const Allocator& a);
41
+ template<class T>
42
+ basic_ostringstream(const T& t, ios_base::openmode which, const Allocator& a);
43
  basic_ostringstream(const basic_ostringstream&) = delete;
44
  basic_ostringstream(basic_ostringstream&& rhs);
45
 
46
  basic_ostringstream& operator=(const basic_ostringstream&) = delete;
47
  basic_ostringstream& operator=(basic_ostringstream&& rhs);
 
60
 
61
  void str(const basic_string<charT, traits, Allocator>& s);
62
  template<class SAlloc>
63
  void str(const basic_string<charT, traits, SAlloc>& s);
64
  void str(basic_string<charT, traits, Allocator>&& s);
65
+ template<class T>
66
+ void str(const T& t);
67
 
68
  private:
69
  basic_stringbuf<charT, traits, Allocator> sb; // exposition only
70
  };
71
  }
 
74
  The class `basic_ostringstream<charT, traits, Allocator>` supports
75
  writing objects of class `basic_string<{}charT, traits, Allocator>`. It
76
  uses a `basic_stringbuf` object to control the associated storage. For
77
  the sake of exposition, the maintained data is presented here as:
78
 
79
+ - *`sb`*, the `stringbuf` object.
80