Home | History | Annotate | Download | only in syntax

Lines Matching refs:regexp

7 // Simplify returns a regexp equivalent to re but without counted repetitions
9 // The resulting regexp will execute correctly but its string representation
13 // The returned regexp may share structure with or be the original.
14 func (re *Regexp) Simplify() *Regexp {
20 // Simplify children, building new Regexp if children change.
26 nre = new(Regexp)
45 return &Regexp{Op: OpEmptyMatch}
64 nre := &Regexp{Op: OpConcat}
85 var prefix *Regexp
87 prefix = &Regexp{Op: OpConcat}
98 nre2 := &Regexp{Op: OpConcat}
113 return &Regexp{Op: OpNoMatch}
120 // OpPlus, and OpQuest operators. It returns the simple regexp
123 // Regexp{Op: op, Flags: flags, Sub: {sub}}
126 // without first allocating that structure. If the regexp
134 func simplify1(op Op, flags Flags, sub, re *Regexp) *Regexp {
148 re = &Regexp{Op: op, Flags: flags}