tmp/tmp3969147l/{from.md → to.md}
RENAMED
|
@@ -1,15 +1,15 @@
|
|
| 1 |
-
## Regular expression algorithms <a id="re.alg">[[re.alg]]</a>
|
| 2 |
|
| 3 |
-
### Exceptions <a id="re.except">[[re.except]]</a>
|
| 4 |
|
| 5 |
The algorithms described in subclause [[re.alg]] may throw an exception
|
| 6 |
of type `regex_error`. If such an exception `e` is thrown, `e.code()`
|
| 7 |
shall return either `regex_constants::error_complexity` or
|
| 8 |
`regex_constants::error_stack`.
|
| 9 |
|
| 10 |
-
### `regex_match` <a id="re.alg.match">[[re.alg.match]]</a>
|
| 11 |
|
| 12 |
``` cpp
|
| 13 |
template<class BidirectionalIterator, class Allocator, class charT, class traits>
|
| 14 |
bool regex_match(BidirectionalIterator first, BidirectionalIterator last,
|
| 15 |
match_results<BidirectionalIterator, Allocator>& m,
|
|
@@ -103,22 +103,22 @@ template<class charT, class traits>
|
|
| 103 |
const basic_regex<charT, traits>& e,
|
| 104 |
regex_constants::match_flag_type flags = regex_constants::match_default);
|
| 105 |
```
|
| 106 |
|
| 107 |
*Returns:*
|
| 108 |
-
`regex_match(str, str + char_traits<charT>::length(str), e, flags)`
|
| 109 |
|
| 110 |
``` cpp
|
| 111 |
template<class ST, class SA, class charT, class traits>
|
| 112 |
bool regex_match(const basic_string<charT, ST, SA>& s,
|
| 113 |
const basic_regex<charT, traits>& e,
|
| 114 |
regex_constants::match_flag_type flags = regex_constants::match_default);
|
| 115 |
```
|
| 116 |
|
| 117 |
*Returns:* `regex_match(s.begin(), s.end(), e, flags)`.
|
| 118 |
|
| 119 |
-
### `regex_search` <a id="re.alg.search">[[re.alg.search]]</a>
|
| 120 |
|
| 121 |
``` cpp
|
| 122 |
template<class BidirectionalIterator, class Allocator, class charT, class traits>
|
| 123 |
bool regex_search(BidirectionalIterator first, BidirectionalIterator last,
|
| 124 |
match_results<BidirectionalIterator, Allocator>& m,
|
|
@@ -208,11 +208,11 @@ template<class ST, class SA, class charT, class traits>
|
|
| 208 |
regex_constants::match_flag_type flags = regex_constants::match_default);
|
| 209 |
```
|
| 210 |
|
| 211 |
*Returns:* `regex_search(s.begin(), s.end(), e, flags)`.
|
| 212 |
|
| 213 |
-
### `regex_replace` <a id="re.alg.replace">[[re.alg.replace]]</a>
|
| 214 |
|
| 215 |
``` cpp
|
| 216 |
template<class OutputIterator, class BidirectionalIterator,
|
| 217 |
class traits, class charT, class ST, class SA>
|
| 218 |
OutputIterator
|
|
|
|
| 1 |
+
### Regular expression algorithms <a id="re.alg">[[re.alg]]</a>
|
| 2 |
|
| 3 |
+
#### Exceptions <a id="re.except">[[re.except]]</a>
|
| 4 |
|
| 5 |
The algorithms described in subclause [[re.alg]] may throw an exception
|
| 6 |
of type `regex_error`. If such an exception `e` is thrown, `e.code()`
|
| 7 |
shall return either `regex_constants::error_complexity` or
|
| 8 |
`regex_constants::error_stack`.
|
| 9 |
|
| 10 |
+
#### `regex_match` <a id="re.alg.match">[[re.alg.match]]</a>
|
| 11 |
|
| 12 |
``` cpp
|
| 13 |
template<class BidirectionalIterator, class Allocator, class charT, class traits>
|
| 14 |
bool regex_match(BidirectionalIterator first, BidirectionalIterator last,
|
| 15 |
match_results<BidirectionalIterator, Allocator>& m,
|
|
|
|
| 103 |
const basic_regex<charT, traits>& e,
|
| 104 |
regex_constants::match_flag_type flags = regex_constants::match_default);
|
| 105 |
```
|
| 106 |
|
| 107 |
*Returns:*
|
| 108 |
+
`regex_match(str, str + char_traits<charT>::length(str), e, flags)`.
|
| 109 |
|
| 110 |
``` cpp
|
| 111 |
template<class ST, class SA, class charT, class traits>
|
| 112 |
bool regex_match(const basic_string<charT, ST, SA>& s,
|
| 113 |
const basic_regex<charT, traits>& e,
|
| 114 |
regex_constants::match_flag_type flags = regex_constants::match_default);
|
| 115 |
```
|
| 116 |
|
| 117 |
*Returns:* `regex_match(s.begin(), s.end(), e, flags)`.
|
| 118 |
|
| 119 |
+
#### `regex_search` <a id="re.alg.search">[[re.alg.search]]</a>
|
| 120 |
|
| 121 |
``` cpp
|
| 122 |
template<class BidirectionalIterator, class Allocator, class charT, class traits>
|
| 123 |
bool regex_search(BidirectionalIterator first, BidirectionalIterator last,
|
| 124 |
match_results<BidirectionalIterator, Allocator>& m,
|
|
|
|
| 208 |
regex_constants::match_flag_type flags = regex_constants::match_default);
|
| 209 |
```
|
| 210 |
|
| 211 |
*Returns:* `regex_search(s.begin(), s.end(), e, flags)`.
|
| 212 |
|
| 213 |
+
#### `regex_replace` <a id="re.alg.replace">[[re.alg.replace]]</a>
|
| 214 |
|
| 215 |
``` cpp
|
| 216 |
template<class OutputIterator, class BidirectionalIterator,
|
| 217 |
class traits, class charT, class ST, class SA>
|
| 218 |
OutputIterator
|