go/src/regexp/exec.go

type queue

type entry

type thread

type machine

type inputs

func (i *inputs) newBytes(b []byte) input {}

func (i *inputs) newString(s string) input {}

func (i *inputs) newReader(r io.RuneReader) input {}

func (i *inputs) clear() {}

func (i *inputs) init(r io.RuneReader, b []byte, s string) (input, int) {}

func (m *machine) init(ncap int) {}

// alloc allocates a new thread with the given instruction.
// It uses the free pool if possible.
func (m *machine) alloc(i *syntax.Inst) *thread {}

type lazyFlag

func newLazyFlag(r1, r2 rune) lazyFlag {}

func (f lazyFlag) match(op syntax.EmptyOp) bool {}

// match runs the machine over the input starting at pos.
// It reports whether a match was found.
// If so, m.matchcap holds the submatch information.
func (m *machine) match(i input, pos int) bool {}

// clear frees all threads on the thread queue.
func (m *machine) clear(q *queue) {}

// step executes one step of the machine, running each of the threads
// on runq and appending new threads to nextq.
// The step processes the rune c (which may be endOfText),
// which starts at position pos and ends at nextPos.
// nextCond gives the setting for the empty-width flags after c.
func (m *machine) step(runq, nextq *queue, pos, nextPos int, c rune, nextCond *lazyFlag) {}

// add adds an entry to q for pc, unless the q already has such an entry.
// It also recursively adds an entry for all instructions reachable from pc by following
// empty-width conditions satisfied by cond.  pos gives the current position
// in the input.
func (m *machine) add(q *queue, pc uint32, pos int, cap []int, cond *lazyFlag, t *thread) *thread {}

type onePassMachine

var onePassPool

func newOnePassMachine() *onePassMachine {}

func freeOnePassMachine(m *onePassMachine) {}

// doOnePass implements r.doExecute using the one-pass execution engine.
func (re *Regexp) doOnePass(ir io.RuneReader, ib []byte, is string, pos, ncap int, dstCap []int) []int {}

// doMatch reports whether either r, b or s match the regexp.
func (re *Regexp) doMatch(r io.RuneReader, b []byte, s string) bool {}

// doExecute finds the leftmost match in the input, appends the position
// of its subexpressions to dstCap and returns dstCap.
//
// nil is returned if no matches are found and non-nil if matches are found.
func (re *Regexp) doExecute(r io.RuneReader, b []byte, s string, pos int, ncap int, dstCap []int) []int {}

var arrayNoInts