crosslang/golang-lean/GolangLean/Parser.lean
Maximus Gorog fd3d42ae33 Add 'golang-lean/' from commit 'f5f17019224c6a6c319387214ceb8e29d09251c6'
git-subtree-dir: golang-lean
git-subtree-mainline: 6487c7046f
git-subtree-split: f5f1701922
2026-05-12 02:59:14 -06:00

16 lines
469 B
Text

import GolangLean.Scanner
import GolangLean.AST
namespace GolangLean
/-! # Parser — port of `go/parser/parser.go`.
Stub. Recursive-descent over the token stream. We mirror upstream: each
non-terminal in the Go spec corresponds to one `parseX` function, named
identically. -/
partial def parseFile (src : String) : Except GoError GoFile := do
let _toks ← scan src
.error (.notImpl "Parser.parseFile: see go-upstream/src/go/parser/parser.go")
end GolangLean