From Jason Turner

[template.bitset]

Diff to HTML by rtfpessoa

tmp/tmpl8rbgpfj/{from.md → to.md} RENAMED
@@ -85,11 +85,11 @@ namespace std {
85
  class traits = char_traits<charT>,
86
  class Allocator = allocator<charT> >
87
  basic_string<charT, traits, Allocator>
88
  to_string(charT zero = charT('0'), charT one = charT('1')) const;
89
  size_t count() const noexcept;
90
- constexpr size_t size() noexcept;
91
  bool operator==(const bitset<N>& rhs) const noexcept;
92
  bool operator!=(const bitset<N>& rhs) const noexcept;
93
  bool test(size_t pos) const;
94
  bool all() const noexcept;
95
  bool any() const noexcept;
@@ -170,13 +170,13 @@ position `pos` is other than `zero` or `one`. The function uses
170
  Otherwise, the function constructs an object of class `bitset<N>`,
171
  initializing the first `M` bit positions to values determined from the
172
  corresponding characters in the string `str`. `M` is the smaller of `N`
173
  and `rlen`.
174
 
175
- An element of the constructed string has value zero if the corresponding
176
- character in `str`, beginning at position `pos`, is `0` `zero`.
177
- Otherwise, the element has the value 1. Character position `pos + M - 1`
178
  corresponds to bit position zero. Subsequent decreasing character
179
  positions correspond to increasing bit positions.
180
 
181
  If `M < N`, remaining bit positions are initialized to zero.
182
 
@@ -369,11 +369,11 @@ size_t count() const noexcept;
369
  ```
370
 
371
  *Returns:* A count of the number of bits set in `*this`.
372
 
373
  ``` cpp
374
- constexpr size_t size() noexcept;
375
  ```
376
 
377
  *Returns:* `N`.
378
 
379
  ``` cpp
@@ -430,11 +430,11 @@ bitset<N> operator>>(size_t pos) const noexcept;
430
  ```
431
 
432
  *Returns:* `bitset<N>(*this) >>= pos`.
433
 
434
  ``` cpp
435
- constexpr bool operator[](size_t pos);
436
  ```
437
 
438
  *Requires:* `pos` shall be valid.
439
 
440
  *Returns:* `true` if the bit at position `pos` in `*this` has the value
@@ -463,12 +463,12 @@ entire underlying bitset.
463
 
464
  ``` cpp
465
  template <size_t N> struct hash<bitset<N> >;
466
  ```
467
 
468
- *Requires:* the template specialization shall meet the requirements of
469
- class template `hash` ([[unord.hash]]).
470
 
471
  ### `bitset` operators <a id="bitset.operators">[[bitset.operators]]</a>
472
 
473
  ``` cpp
474
  bitset<N> operator&(const bitset<N>& lhs, const bitset<N>& rhs) noexcept;
 
85
  class traits = char_traits<charT>,
86
  class Allocator = allocator<charT> >
87
  basic_string<charT, traits, Allocator>
88
  to_string(charT zero = charT('0'), charT one = charT('1')) const;
89
  size_t count() const noexcept;
90
+ constexpr size_t size() const noexcept;
91
  bool operator==(const bitset<N>& rhs) const noexcept;
92
  bool operator!=(const bitset<N>& rhs) const noexcept;
93
  bool test(size_t pos) const;
94
  bool all() const noexcept;
95
  bool any() const noexcept;
 
170
  Otherwise, the function constructs an object of class `bitset<N>`,
171
  initializing the first `M` bit positions to values determined from the
172
  corresponding characters in the string `str`. `M` is the smaller of `N`
173
  and `rlen`.
174
 
175
+ An element of the constructed object has value zero if the corresponding
176
+ character in `str`, beginning at position `pos`, is `zero`. Otherwise,
177
+ the element has the value one. Character position `pos + M - 1`
178
  corresponds to bit position zero. Subsequent decreasing character
179
  positions correspond to increasing bit positions.
180
 
181
  If `M < N`, remaining bit positions are initialized to zero.
182
 
 
369
  ```
370
 
371
  *Returns:* A count of the number of bits set in `*this`.
372
 
373
  ``` cpp
374
+ constexpr size_t size() const noexcept;
375
  ```
376
 
377
  *Returns:* `N`.
378
 
379
  ``` cpp
 
430
  ```
431
 
432
  *Returns:* `bitset<N>(*this) >>= pos`.
433
 
434
  ``` cpp
435
+ constexpr bool operator[](size_t pos) const;
436
  ```
437
 
438
  *Requires:* `pos` shall be valid.
439
 
440
  *Returns:* `true` if the bit at position `pos` in `*this` has the value
 
463
 
464
  ``` cpp
465
  template <size_t N> struct hash<bitset<N> >;
466
  ```
467
 
468
+ The template specialization shall meet the requirements of class
469
+ template `hash` ([[unord.hash]]).
470
 
471
  ### `bitset` operators <a id="bitset.operators">[[bitset.operators]]</a>
472
 
473
  ``` cpp
474
  bitset<N> operator&(const bitset<N>& lhs, const bitset<N>& rhs) noexcept;