Remove NewRegexpMatcher and panic on error instead

Signed-off-by: Kiril Vladimirov <kiril@vladimiroff.org>
This commit is contained in:
Kiril Vladimirov 2021-01-21 10:56:06 +02:00
parent f5382af591
commit 97e0c754c0
1 changed files with 0 additions and 8 deletions

View File

@ -152,11 +152,3 @@ func (ms Matchers) String() string {
return buf.String()
}
// NewRegexpMatcher returns a matcher with already compiled regexp.Regexp.
//
// TODO(vladimiroff): Get rid of this function once migration from
// types.Matcher is complete.
func NewRegexpMatcher(n string, re *regexp.Regexp) *Matcher {
return &Matcher{Type: MatchRegexp, Name: n, Value: re.String(), re: re}
}