From Jason Turner

[ostream.inserters.character]

Diff to HTML by rtfpessoa

tmp/tmpa1bnmz0a/{from.md → to.md} RENAMED
@@ -14,16 +14,16 @@ template<class traits>
14
  template<class traits>
15
  basic_ostream<char, traits>& operator<<(basic_ostream<char, traits>& out, unsigned char c);
16
  ```
17
 
18
  *Effects:* Behaves as a formatted output
19
- function ([[ostream.formatted.reqmts]]) of `out`. Constructs a
20
- character sequence `seq`. If `c` has type `char` and the character type
21
- of the stream is not `char`, then `seq` consists of `out.widen(c)`;
22
- otherwise `seq` consists of `c`. Determines padding for `seq` as
23
- described in  [[ostream.formatted.reqmts]]. Inserts `seq` into `out`.
24
- Calls `os.width(0)`.
25
 
26
  *Returns:* `out`.
27
 
28
  ``` cpp
29
  template<class charT, class traits>
@@ -37,17 +37,17 @@ template<class traits>
37
  template<class traits>
38
  basic_ostream<char, traits>& operator<<(basic_ostream<char, traits>& out,
39
  const unsigned char* s);
40
  ```
41
 
42
- *Requires:* `s` shall not be a null pointer.
43
 
44
  *Effects:* Behaves like a formatted inserter (as described
45
  in  [[ostream.formatted.reqmts]]) of `out`. Creates a character sequence
46
  `seq` of `n` characters starting at `s`, each widened using
47
- `out.widen()` ([[basic.ios.members]]), where `n` is the number that
48
- would be computed as if by:
49
 
50
  - `traits::length(s)` for the overload where the first argument is of
51
  type `basic_ostream<charT, traits>&` and the second is of type
52
  `const charT*`, and also for the overload where the first argument is
53
  of type `basic_ostream<char, traits>&` and the second is of type
 
14
  template<class traits>
15
  basic_ostream<char, traits>& operator<<(basic_ostream<char, traits>& out, unsigned char c);
16
  ```
17
 
18
  *Effects:* Behaves as a formatted output
19
+ function [[ostream.formatted.reqmts]] of `out`. Constructs a character
20
+ sequence `seq`. If `c` has type `char` and the character type of the
21
+ stream is not `char`, then `seq` consists of `out.widen(c)`; otherwise
22
+ `seq` consists of `c`. Determines padding for `seq` as described
23
+ in  [[ostream.formatted.reqmts]]. Inserts `seq` into `out`. Calls
24
+ `os.width(0)`.
25
 
26
  *Returns:* `out`.
27
 
28
  ``` cpp
29
  template<class charT, class traits>
 
37
  template<class traits>
38
  basic_ostream<char, traits>& operator<<(basic_ostream<char, traits>& out,
39
  const unsigned char* s);
40
  ```
41
 
42
+ *Preconditions:* `s` is not a null pointer.
43
 
44
  *Effects:* Behaves like a formatted inserter (as described
45
  in  [[ostream.formatted.reqmts]]) of `out`. Creates a character sequence
46
  `seq` of `n` characters starting at `s`, each widened using
47
+ `out.widen()` [[basic.ios.members]], where `n` is the number that would
48
+ be computed as if by:
49
 
50
  - `traits::length(s)` for the overload where the first argument is of
51
  type `basic_ostream<charT, traits>&` and the second is of type
52
  `const charT*`, and also for the overload where the first argument is
53
  of type `basic_ostream<char, traits>&` and the second is of type