php-dextrin

DXNRegex.php

Table of Contents

Classes

DXNRegex
DXN `regex` (`~r/pattern/flags`) -- PCRE-style semantics (matching Erlang `:re`/Elixir `Regex`, per `dxn/DXN.md` ยง2.3), which happens to make PHP's own PCRE-backed `preg_*` a *better* native fit than JS's `RegExp` had: DXN's `x` (extended) and `r` (ungreedy) flags both have real PHP modifier equivalents (`r` maps to PHP's uppercase `U`, distinct from lowercase `u`/unicode) where JS had neither. Only `f` (firstline) has no PHP preg modifier to reach for, so {@see self::toPcrePattern()} is guarded on that alone, not on `x`/`f`/`r` wholesale.
On this page

Search results