FIX:
* Yeah so the ReMap.Map* stuff was kind of broken hard. It's fixed now.
This commit is contained in:
brent saner
2025-08-04 04:26:52 +00:00
parent 154170c0e5
commit 368ae0cb8e
2 changed files with 273 additions and 21 deletions

View File

@@ -4,7 +4,20 @@ import (
`regexp`
)
// ReMap provides some map-related functions around a regexp.Regexp.
type ReMap struct {
*regexp.Regexp
}
type (
// ReMap provides some map-related functions around a regexp.Regexp.
ReMap struct {
*regexp.Regexp
}
/*
ExplicitStringMatch is used with ReMap.MapStringExplicit to indicate if a
capture group result is a hit (a group matched, but e.g. the match value is empty string)
or not (a group did not match)
*/
ExplicitStringMatch struct {
Group string
IsMatch bool
Value string
}
)