We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 114eec6 commit abd37d1Copy full SHA for abd37d1
1 file changed
datafusion/functions/src/regex/regexpreplace.rs
@@ -205,6 +205,8 @@ fn regex_replace_posix_groups(replacement: &str) -> String {
205
/// is `\1`, build a shorter regex (stripping trailing `.*$`) and use
206
/// `captures_read` with `CaptureLocations` for direct extraction — no
207
/// `expand()`, no `String` allocation.
208
+/// This pattern appears in ClickBench Q28: which uses a regexp like
209
+/// `^https?://(?:www\.)?([^/]+)/.*$`
210
fn try_build_short_extract_regex(pattern: &str, replacement: &str) -> Option<Regex> {
211
if replacement != "${1}" || !pattern.starts_with('^') || !pattern.ends_with(".*$") {
212
return None;
0 commit comments