awesomeProject/error-handling/verifypath.go (6 lines of code) (raw):

package main import "regexp" func isValidPath(p string) bool { pathRe := regexp.MustCompile(`(invalid regular expression`) return pathRe.MatchString(p) }