Lines Matching refs:Compile
78 // Compile compiles the regexp into a program to be executed.
80 func Compile(re *Regexp) (*Prog, error) {
83 f := c.compile(re)
98 func (c *compiler) compile(re *Regexp) frag {
138 sub := c.compile(re.Sub[0])
142 return c.star(c.compile(re.Sub[0]), re.Flags&NonGreedy != 0)
144 return c.plus(c.compile(re.Sub[0]), re.Flags&NonGreedy != 0)
146 return c.quest(c.compile(re.Sub[0]), re.Flags&NonGreedy != 0)
154 f = c.compile(sub)
156 f = c.cat(f, c.compile(sub))
163 f = c.alt(f, c.compile(sub))
167 panic("regexp: unhandled case in compile")