MCPcopy Create free account
hub / github.com/cel-expr/cel-go / NewTextSourceWithLimit

Function NewTextSourceWithLimit

common/source.go:79–81  ·  view source on GitHub ↗

NewTextSourceWithLimit creates a new Source from the input text string while enforcing a maximum code point count when needed.

(text string, limit int)

Source from the content-addressed store, hash-verified

77// NewTextSourceWithLimit creates a new Source from the input text string while
78// enforcing a maximum code point count when needed.
79func NewTextSourceWithLimit(text string, limit int) (Source, error) {
80 return NewStringSourceWithLimit(text, "<input>", limit)
81}
82
83// NewStringSource creates a new Source from the given contents and description.
84func NewStringSource(contents string, description string) Source {

Callers 4

CompileMethod · 0.92
ParseMethod · 0.92

Calls 1

NewStringSourceWithLimitFunction · 0.85