|
REAL
Regular Expression Algorithmic Library — constexpr C++20 regex
|
Compiled form of a pattern and the public flags / error types. More...
#include "real/version.hpp"#include <array>#include <cstdint>#include <exception>#include <limits>#include <span>#include <string>#include <vector>#include "real/core/charclass.hpp"Go to the source code of this file.
Classes | |
| class | real::regex_error |
| struct | real::detail::code_range |
An inclusive code-point range [lo, hi]. Shared by character classes (ast.hpp) and the generated Unicode property / fold tables; lives here so those low-level headers need not pull in the parser. More... | |
| struct | real::detail::cp_class |
A match-time code-point class for the klass_cp opcode: an ASCII bitmap for code points < 0x80 plus a slice of sorted non-ASCII ranges (indexing the program's flat cp_ranges buffer). It is the already-effective set (any \W/[^…] negation is materialised at compile time). Unlike the byte-NFA klass, the ranges are kept and binary-searched at match time — O(log ranges) per position, independent of the range count. More... | |
| struct | real::detail::lookaround_sub |
A bounded lookaround sub-program, referenced by assert_lookaround's arg16. More... | |
| struct | real::detail::instr |
| One NFA instruction. Field meaning depends on op. More... | |
| struct | real::detail::pattern_hints |
| Search-acceleration hints extracted from a compiled program. More... | |
| struct | real::detail::named_group |
| A named capture group. More... | |
| struct | real::detail::program_view |
| struct | real::detail::dynamic_program |
Owning, heap-allocated program: the storage backing real::regex. More... | |
Namespaces | |
| namespace | real |
| namespace | real::detail |
Functions | |
| constexpr flags | real::operator| (flags lhs, flags rhs) |
| Bitwise-OR of two flag sets. | |
| constexpr flags | real::operator& (flags lhs, flags rhs) |
| Bitwise-AND of two flag sets. | |
| constexpr bool | real::has_flag (flags value, flags flag) |
Tests whether flag is set in value. | |
Variables | |
| constexpr std::size_t | real::npos {std::numeric_limits<std::size_t>::max()} |
| Sentinel for "no position" / unset capture slot (akin to std::string::npos). | |
Compiled form of a pattern and the public flags / error types.
Defines the NFA instruction set executed by the engine, the heap-allocated program the compiler produces, the non-owning view the engine runs over, the compilation real::flags, and real::regex_error (thrown on an invalid pattern).
Definition in file program.hpp.