MCPcopy
hub / github.com/alecthomas/participle / Parse

Function Parse

_examples/basic/ast.go:12–19  ·  view source on GitHub ↗

Parse a BASIC program.

(r io.Reader)

Source from the content-addressed store, hash-verified

10
11// Parse a BASIC program.
12func Parse(r io.Reader) (*Program, error) {
13 program, err := basicParser.Parse("", r)
14 if err != nil {
15 return nil, err
16 }
17 program.init()
18 return program, nil
19}
20
21type Program struct {
22 Pos lexer.Position

Callers 2

TestExeFunction · 0.70
mainFunction · 0.70

Calls 2

initMethod · 0.80
ParseMethod · 0.65

Tested by 1

TestExeFunction · 0.56

Used in the wild real call sites across dependent graphs

searching dependent graphs…