code: func parseMatcher(pat string) (matcher Matcher, name string) {
  	if !isMatchPattern(pat) {
  		panic("pattern \"" + pat + "\" is not a matcher pattern")
  	}
  
  	s := pat[1 : len(pat)-1]
  	ss := strings.Split(s, ":")
  	var matchType string
  	if len(ss) == 1 {
  		name = ss[0]
  	} else {
  		matchType = ss[0]
  		name = ss[1]
  	}
  	if matchType == "" {
  		matchType = "default"
  	}
  
  	matcher = MatcherMap[matchType]
  	if matcher == nil {
  		panic(errors.New("no such match type: " + matchType))
  	}
  
  	return matcher, name
  }
docs: // parseMatcher returns matcher and name from the given pattern string.