MCPcopy Create free account
hub / github.com/expr-lang/expr / accept

Method accept

parser/lexer/lexer.go:145–151  ·  view source on GitHub ↗
(valid string)

Source from the content-addressed store, hash-verified

143}
144
145func (l *Lexer) accept(valid string) bool {
146 if strings.ContainsRune(valid, l.peek()) {
147 l.next()
148 return true
149 }
150 return false
151}
152
153func (l *Lexer) acceptRun(valid string) {
154 for l.accept(valid) {

Callers 8

scanNumberMethod · 0.95
acceptRunMethod · 0.95
rootFunction · 0.80
dotFunction · 0.80
questionMarkFunction · 0.80
slashFunction · 0.80
multiLineCommentFunction · 0.80
pointerFunction · 0.80

Calls 2

peekMethod · 0.95
nextMethod · 0.95

Tested by

no test coverage detected