Files
2025-10-25 03:02:53 +03:00

51 lines
2.9 KiB
Markdown
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

[re.general]
# 28 Text processing library [[text]](./#text)
## 28.6 Regular expressions library [[re]](re#general)
### 28.6.1 General [re.general]
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/text.tex#L8998)
Subclause [[re]](re "28.6Regular expressions library") describes components that C++ programs may use to
perform operations involving regular expression matching and
searching[.](#1.sentence-1)
[2](#2)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/text.tex#L9003)
The following subclauses describe a basic regular expression class template and its
traits that can handle char-like ([[strings.general]](strings.general "27.1General")) template arguments,
two specializations of this class template that handle sequences of char and wchar_t,
a class template that holds the
result of a regular expression match, a series of algorithms that allow a character
sequence to be operated upon by a regular expression,
and two iterator types for
enumerating regular expression matches, as summarized in Table [117](#tab:re.summary "Table 117: Regular expressions library summary")[.](#2.sentence-1)
Table [117](#tab:re.summary) — Regular expressions library summary [[tab:re.summary]](./tab:re.summary)
| [🔗](#tab:re.summary-row-1) | **Subclause** | **Header** |
| --- | --- | --- |
| [🔗](#tab:re.summary-row-2)<br>[[re.req]](re.req "28.6.2Requirements") | Requirements | |
| [🔗](#tab:re.summary-row-3)<br>[[re.const]](re.const "28.6.4Namespace std::regex_­constants") | Constants | <regex> |
| [🔗](#tab:re.summary-row-4)<br>[[re.badexp]](re.badexp "28.6.5Class regex_­error") | Exception type | |
| [🔗](#tab:re.summary-row-5)<br>[[re.traits]](re.traits "28.6.6Class template regex_­traits") | Traits | |
| [🔗](#tab:re.summary-row-6)<br>[[re.regex]](re.regex "28.6.7Class template basic_­regex") | Regular expression template | |
| [🔗](#tab:re.summary-row-7)<br>[[re.submatch]](re.submatch "28.6.8Class template sub_­match") | Submatches | |
| [🔗](#tab:re.summary-row-8)<br>[[re.results]](re.results "28.6.9Class template match_­results") | Match results | |
| [🔗](#tab:re.summary-row-9)<br>[[re.alg]](re.alg "28.6.10Regular expression algorithms") | Algorithms | |
| [🔗](#tab:re.summary-row-10)<br>[[re.iter]](re.iter "28.6.11Regular expression iterators") | Iterators | |
| [🔗](#tab:re.summary-row-11)<br>[[re.grammar]](re.grammar "28.6.12Modified ECMAScript regular expression grammar") | Grammar | |
[3](#3)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/text.tex#L9026)
The ECMAScript Language Specification described in Standard Ecma-262
is called [*ECMA-262*](#def:ECMA-262 "28.6.1General[re.general]") in this Clause[.](#3.sentence-1)