File: .lake/packages/lean4/src/lean/Lean/Parser/Basic.lean

full_name: Lean.Parser.dbgTraceStateFn
code: def dbgTraceStateFn (label : String) (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.dbgTraceState
code: def dbgTraceState (label : String) : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.epsilonInfo
code: @[noinline]def epsilonInfo : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.checkStackTopFn
code: def checkStackTopFn (p : Syntax → Bool) (msg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkStackTop
code: def checkStackTop (p : Syntax → Bool) (msg : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.andthenFn
code: def andthenFn (p q : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.andthenInfo
code: @[noinline] def andthenInfo (p q : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.andthen
code: /-- The `andthen(p, q)` combinator, usually written as adjacency in syntax declarations (`p q`),
parses `p` followed by `q`.

The arity of this parser is the sum of the arities of `p` and `q`:
that is, it accumulates all the nodes produced by `p` followed by the nodes from `q` into the list
of arguments to the surrounding parse node. -/
def andthen (p q : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.«instAndThenParser_.lake»
code: instance : AndThen Parser 
goal: AndThen Lean.Parser.Parser

full_name: Lean.Parser.nodeFn
code: def nodeFn (n : SyntaxNodeKind) (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.trailingNodeFn
code: def trailingNodeFn (n : SyntaxNodeKind) (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.nodeInfo
code: @[noinline] def nodeInfo (n : SyntaxNodeKind) (p : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.node
code: def node (n : SyntaxNodeKind) (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.errorFn
code: def errorFn (msg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.error
code: def error (msg : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.errorAtSavedPosFn
code: def errorAtSavedPosFn (msg : String) (delta : Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.errorAtSavedPos
code: /-- Generate an error at the position saved with the `withPosition` combinator.
   If `delta == true`, then it reports at saved position+1.
   This useful to make sure a parser consumed at least one character.  -/
def errorAtSavedPos (msg : String) (delta : Bool) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkPrecFn
code: /-- Succeeds if `c.prec <= prec` -/
def checkPrecFn (prec : Nat) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkPrec
code: def checkPrec (prec : Nat) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkLhsPrecFn
code: /-- Succeeds if `c.lhsPrec >= prec` -/
def checkLhsPrecFn (prec : Nat) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkLhsPrec
code: def checkLhsPrec (prec : Nat) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.setLhsPrecFn
code: def setLhsPrecFn (prec : Nat) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.setLhsPrec
code: def setLhsPrec (prec : Nat) : Parser 
goal: Lean.Parser.Parser

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.addQuotDepth
code: private def addQuotDepth (i : Int) (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.incQuotDepth
code: def incQuotDepth (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.decQuotDepth
code: def decQuotDepth (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.suppressInsideQuot
code: def suppressInsideQuot : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.leadingNode
code: def leadingNode (n : SyntaxNodeKind) (prec : Nat) (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.trailingNodeAux
code: def trailingNodeAux (n : SyntaxNodeKind) (p : Parser) : TrailingParser 
goal: Lean.Parser.TrailingParser

full_name: Lean.Parser.trailingNode
code: def trailingNode (n : SyntaxNodeKind) (prec lhsPrec : Nat) (p : Parser) : TrailingParser 
goal: Lean.Parser.TrailingParser

full_name: Lean.Parser.mergeOrElseErrors
code: def mergeOrElseErrors (s : ParserState) (error1 : Error) (iniPos : String.Pos) (mergeErrors : Bool) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.OrElseOnAntiquotBehavior
code: inductive OrElseOnAntiquotBehavior where
  | acceptLhs    -- return it
  | takeLongest  -- return result of `q` instead if it made more progress
  | merge        -- ... and create choice node if both made the same progress
  deriving BEq
goal: Type

full_name: Lean.Parser.OrElseOnAntiquotBehavior.acceptLhs
code: inductive OrElseOnAntiquotBehavior where
  | acceptLhs    -- return it
  | takeLongest  -- return result of `q` instead if it made more progress
  | merge        -- ... and create choice node if both made the same progress
  deriving BEq
goal: Lean.Parser.OrElseOnAntiquotBehavior

full_name: Lean.Parser.OrElseOnAntiquotBehavior.merge
code: inductive OrElseOnAntiquotBehavior where
  | acceptLhs    -- return it
  | takeLongest  -- return result of `q` instead if it made more progress
  | merge        -- ... and create choice node if both made the same progress
  deriving BEq
goal: Lean.Parser.OrElseOnAntiquotBehavior

full_name: Lean.Parser.OrElseOnAntiquotBehavior.takeLongest
code: inductive OrElseOnAntiquotBehavior where
  | acceptLhs    -- return it
  | takeLongest  -- return result of `q` instead if it made more progress
  | merge        -- ... and create choice node if both made the same progress
  deriving BEq
goal: Lean.Parser.OrElseOnAntiquotBehavior

full_name: Lean.Parser.instBEqOrElseOnAntiquotBehavior
code: BEq
goal: BEq Lean.Parser.OrElseOnAntiquotBehavior

full_name: Lean.Parser.orelseFnCore
code: def orelseFnCore (p q : ParserFn) (antiquotBehavior := OrElseOnAntiquotBehavior.merge) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.orelseFn
code: def orelseFn (p q : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.orelseInfo
code: @[noinline] def orelseInfo (p q : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.orelse
code: /--
  Run `p`, falling back to `q` if `p` failed without consuming any input.

  NOTE: In order for the pretty printer to retrace an `orelse`, `p` must be a call to `node` or some other parser
  producing a single node kind. Nested `orelse` calls are flattened for this, i.e. `(node k1 p1 <|> node k2 p2) <|> ...`
  is fine as well. -/
def orelse (p q : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.«instOrElseParser_.lake»
code: instance : OrElse Parser 
goal: OrElse Lean.Parser.Parser

full_name: Lean.Parser.noFirstTokenInfo
code: @[noinline] def noFirstTokenInfo (info : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.atomicFn
code: def atomicFn (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.atomic
code: /-- The `atomic(p)` parser parses `p`, returns the same result as `p` and fails iff `p` fails,
but if `p` fails after consuming some tokens `atomic(p)` will fail without consuming tokens.
This is important for the `p <|> q` combinator, because it is not backtracking, and will fail if
`p` fails after consuming some tokens. To get backtracking behavior, use `atomic(p) <|> q` instead.

This parser has the same arity as `p` - it produces the same result as `p`. -/
def atomic : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.instReprRecoveryContext
code: /-- Information about the state of the parse prior to the failing parser's execution -/
structure RecoveryContext where
  /-- The position prior to the failing parser -/
  initialPos : String.Pos
  /-- The syntax stack height prior to the failing parser's execution -/
  initialSize : Nat
deriving BEq, DecidableEq, Repr
goal: Repr Lean.Parser.RecoveryContext

full_name: Lean.Parser.RecoveryContext
code: /-- Information about the state of the parse prior to the failing parser's execution -/
structure RecoveryContext where
  /-- The position prior to the failing parser -/
  initialPos : String.Pos
  /-- The syntax stack height prior to the failing parser's execution -/
  initialSize : Nat
deriving BEq, DecidableEq, Repr
goal: Type

full_name: Lean.Parser.RecoveryContext.initialSize
code: /-- Information about the state of the parse prior to the failing parser's execution -/
structure RecoveryContext where
  /-- The position prior to the failing parser -/
  initialPos : String.Pos
  /-- The syntax stack height prior to the failing parser's execution -/
  initialSize : Nat
deriving BEq, DecidableEq, Repr
goal: Nat

full_name: Lean.Parser.RecoveryContext.initialPos
code: /-- Information about the state of the parse prior to the failing parser's execution -/
structure RecoveryContext where
  /-- The position prior to the failing parser -/
  initialPos : String.Pos
  /-- The syntax stack height prior to the failing parser's execution -/
  initialSize : Nat
deriving BEq, DecidableEq, Repr
goal: String.Pos

full_name: Lean.Parser.instBEqRecoveryContext
code: /-- Information about the state of the parse prior to the failing parser's execution -/
structure RecoveryContext where
  /-- The position prior to the failing parser -/
  initialPos : String.Pos
  /-- The syntax stack height prior to the failing parser's execution -/
  initialSize : Nat
deriving BEq, DecidableEq, Repr
goal: BEq Lean.Parser.RecoveryContext

full_name: Lean.Parser.recoverFn
code: /--
Recover from errors in `p` using `recover` to consume input until a known-good state has appeared.
If `recover` fails itself, then no recovery is performed.

`recover` is provided with information about the failing parser's effects , and it is run in the
state immediately after the failure. -/
def recoverFn (p : ParserFn) (recover : RecoveryContext → ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.recover'
code: /--
Recover from errors in `parser` using `handler` to consume input until a known-good state has appeared.
If `handler` fails itself, then no recovery is performed.

`handler` is provided with information about the failing parser's effects , and it is run in the
state immediately after the failure.

The interactions between <|> and `recover'` are subtle, especially for syntactic
categories that admit user extension. Consider avoiding it in these cases. -/
def recover' (parser : Parser) (handler : RecoveryContext → Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.recover
code: /--
Recover from errors in `parser` using `handler` to consume input until a known-good state has appeared.
If `handler` fails itself, then no recovery is performed.

`handler` is run in the state immediately after the failure.

The interactions between <|> and `recover` are subtle, especially for syntactic
categories that admit user extension. Consider avoiding it in these cases. -/
def recover (parser handler : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.optionalFn
code: def optionalFn (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.optionaInfo
code: @[noinline] def optionaInfo (p : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.optionalNoAntiquot
code: def optionalNoAntiquot (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.lookaheadFn
code: def lookaheadFn (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.lookahead
code: /-- `lookahead(p)` runs `p` and fails if `p` does, but it produces no parse nodes and rewinds the
position to the original state on success. So for example `lookahead("=>")` will ensure that the
next token is `"=>"`, without actually consuming this token.

This parser has arity 0 - it does not capture anything. -/
def lookahead : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.notFollowedByFn
code: def notFollowedByFn (p : ParserFn) (msg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.notFollowedBy
code: /-- `notFollowedBy(p, "foo")` succeeds iff `p` fails;
if `p` succeeds then it fails with the message `"unexpected foo"`.

This parser has arity 0 - it does not capture anything. -/
def notFollowedBy (p : Parser) (msg : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.manyAux
code: partial def manyAux (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.manyFn
code: def manyFn (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.manyNoAntiquot
code: def manyNoAntiquot (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.many1Fn
code: def many1Fn (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.many1NoAntiquot
code: def many1NoAntiquot : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.sepByFnAux.parse
code: private partial def sepByFnAux (p : ParserFn) (sep : ParserFn) (allowTrailingSep : Bool) (iniSz : Nat) (pOpt : Bool) : ParserFn 
goal: Lean.Parser.ParserState

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.sepByFnAux
code: private partial def sepByFnAux (p : ParserFn) (sep : ParserFn) (allowTrailingSep : Bool) (iniSz : Nat) (pOpt : Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.sepByFn
code: def sepByFn (allowTrailingSep : Bool) (p : ParserFn) (sep : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.sepBy1Fn
code: def sepBy1Fn (allowTrailingSep : Bool) (p : ParserFn) (sep : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.sepByInfo
code: @[noinline] def sepByInfo (p sep : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.sepBy1Info
code: @[noinline] def sepBy1Info (p sep : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.sepByNoAntiquot
code: def sepByNoAntiquot (p sep : Parser) (allowTrailingSep : Bool := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.sepBy1NoAntiquot
code: def sepBy1NoAntiquot (p sep : Parser) (allowTrailingSep : Bool := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withResultOfFn
code: /-- Apply `f` to the syntax object produced by `p` -/
def withResultOfFn (p : ParserFn) (f : Syntax → Syntax) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.withResultOfInfo
code: @[noinline] def withResultOfInfo (p : ParserInfo) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.withResultOf
code: def withResultOf (p : Parser) (f : Syntax → Syntax) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.many1Unbox
code: def many1Unbox (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.satisfyFn
code: partial def satisfyFn (p : Char → Bool) (errorMsg : String := "unexpected character") : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.takeUntilFn
code: partial def takeUntilFn (p : Char → Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.takeWhileFn
code: def takeWhileFn (p : Char → Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.takeWhile1Fn
code: def takeWhile1Fn (p : Char → Bool) (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.finishCommentBlock.eoi
code: partial def finishCommentBlock (nesting : Nat) : ParserFn 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.finishCommentBlock
code: partial def finishCommentBlock (nesting : Nat) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.whitespace
code: /-- Consume whitespace and comments -/
partial def whitespace : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.mkEmptySubstringAt
code: def mkEmptySubstringAt (s : String) (p : String.Pos) : Substring 
goal: Substring

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.rawAux
code: private def rawAux (startPos : String.Pos) (trailingWs : Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.rawFn
code: /-- Match an arbitrary Parser and return the consumed String in a `Syntax.atom`. -/
def rawFn (p : ParserFn) (trailingWs := false) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.chFn
code: def chFn (c : Char) (trailingWs := false) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.rawCh
code: def rawCh (c : Char) (trailingWs := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.hexDigitFn
code: def hexDigitFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.stringGapFn
code: /--
Parses the whitespace after the `\` when there is a string gap.
Raises an error if the whitespace does not contain exactly one newline character.
-/
partial def stringGapFn (seenNewline : Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.quotedCharCoreFn
code: /--
Parses a string quotation after a `\`.
- `isQuotable` determines which characters are valid escapes
- `inString` enables features that are only valid within strings,
  in particular `"\" newline whitespace*` gaps.
-/
def quotedCharCoreFn (isQuotable : Char → Bool) (inString : Bool) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.isQuotableCharDefault
code: def isQuotableCharDefault (c : Char) : Bool 
goal: Bool

full_name: Lean.Parser.quotedCharFn
code: def quotedCharFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.quotedStringFn
code: /--
Like `quotedCharFn` but enables escapes that are only valid inside strings.
In particular, string gaps (`"\" newline whitespace*`).
-/
def quotedStringFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.mkNodeToken
code: /-- Push `(Syntax.node tk <new-atom>)` onto syntax stack if parse was successful. -/
def mkNodeToken (n : SyntaxNodeKind) (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.charLitFnAux
code: def charLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.strLitFnAux
code: partial def strLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.isRawStrLitStart
code: /--
Raw strings have the syntax `r##...#"..."#...##` with zero or more `#`'s.
If we are looking at a valid start to a raw string (`r##...#"`),
returns true.
We assume `i` begins at the position immediately after `r`.
-/
partial def isRawStrLitStart (input : String) (i : String.Pos) : Bool 
goal: Bool

full_name: Lean.Parser.rawStrLitFnAux
code: /--
Parses a raw string literal assuming `isRawStrLitStart` has returned true.
The `startPos` is the start of the raw string (at the `r`).
The parser state is assumed to be immediately after the `r`.
-/
partial def rawStrLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.rawStrLitFnAux.closingState
code: /--
Parses a raw string literal assuming `isRawStrLitStart` has returned true.
The `startPos` is the start of the raw string (at the `r`).
The parser state is assumed to be immediately after the `r`.
-/
partial def rawStrLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserContext → Lean.Parser.ParserState → Lean.Parser.ParserState

full_name: Lean.Parser.rawStrLitFnAux.errorUnterminated
code: /--
Parses a raw string literal assuming `isRawStrLitStart` has returned true.
The `startPos` is the start of the raw string (at the `r`).
The parser state is assumed to be immediately after the `r`.
-/
partial def rawStrLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.rawStrLitFnAux.initState
code: /--
Parses a raw string literal assuming `isRawStrLitStart` has returned true.
The `startPos` is the start of the raw string (at the `r`).
The parser state is assumed to be immediately after the `r`.
-/
partial def rawStrLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserContext → Lean.Parser.ParserState → Lean.Parser.ParserState

full_name: Lean.Parser.rawStrLitFnAux.normalState
code: /--
Parses a raw string literal assuming `isRawStrLitStart` has returned true.
The `startPos` is the start of the raw string (at the `r`).
The parser state is assumed to be immediately after the `r`.
-/
partial def rawStrLitFnAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserContext → Lean.Parser.ParserState → Lean.Parser.ParserState

full_name: Lean.Parser.decimalNumberFn
code: def decimalNumberFn (startPos : String.Pos) (c : ParserContext) : ParserState → ParserState 
goal: Lean.Parser.ParserState → Lean.Parser.ParserState

full_name: Lean.Parser.decimalNumberFn.parseOptDot
code: def decimalNumberFn (startPos : String.Pos) (c : ParserContext) : ParserState → ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.decimalNumberFn.parseOptExp
code: def decimalNumberFn (startPos : String.Pos) (c : ParserContext) : ParserState → ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.binNumberFn
code: def binNumberFn (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.octalNumberFn
code: def octalNumberFn (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.hexNumberFn
code: def hexNumberFn (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.numberFnAux
code: def numberFnAux : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.isIdCont
code: def isIdCont : String → ParserState → Bool 
goal: String → Lean.Parser.ParserState → Bool

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.isToken
code: private def isToken (idStartPos idStopPos : String.Pos) (tk : Option Token) : Bool 
goal: Bool

full_name: Lean.Parser.mkTokenAndFixPos
code: def mkTokenAndFixPos (startPos : String.Pos) (tk : Option Token) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.mkIdResult
code: def mkIdResult (startPos : String.Pos) (tk : Option Token) (val : Name) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.identFnAux.parse
code: partial def identFnAux (startPos : String.Pos) (tk : Option Token) (r : Name) : ParserFn 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.identFnAux
code: partial def identFnAux (startPos : String.Pos) (tk : Option Token) (r : Name) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.isIdFirstOrBeginEscape
code: private def isIdFirstOrBeginEscape (c : Char) : Bool 
goal: Bool

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.nameLitAux
code: private def nameLitAux (startPos : String.Pos) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.tokenFnAux
code: private def tokenFnAux : ParserFn 
goal: Lean.Parser.ParserFn

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.updateTokenCache
code: private def updateTokenCache (startPos : String.Pos) (s : ParserState) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.tokenFn
code: def tokenFn (expected : List String := []) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.peekTokenAux
code: def peekTokenAux (c : ParserContext) (s : ParserState) : ParserState × Except ParserState Syntax 
goal: Lean.Parser.ParserState × Except Lean.Parser.ParserState Lean.Syntax

full_name: Lean.Parser.peekToken
code: def peekToken (c : ParserContext) (s : ParserState) : ParserState × Except ParserState Syntax 
goal: Lean.Parser.ParserState × Except Lean.Parser.ParserState Lean.Syntax

full_name: Lean.Parser.rawIdentFn
code: /-- Treat keywords as identifiers. -/
def rawIdentFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.satisfySymbolFn
code: def satisfySymbolFn (p : String → Bool) (expected : List String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.symbolFnAux
code: def symbolFnAux (sym : String) (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.symbolInfo
code: def symbolInfo (sym : String) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.symbolFn
code: def symbolFn (sym : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.symbolNoAntiquot
code: def symbolNoAntiquot (sym : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkTailNoWs
code: def checkTailNoWs (prev : Syntax) : Bool 
goal: Bool

full_name: Lean.Parser.nonReservedSymbolFnAux
code: /-- Check if the following token is the symbol _or_ identifier `sym`. Useful for
    parsing local tokens that have not been added to the token table (but may have
    been so by some unrelated code).

    For example, the universe `max` Function is parsed using this combinator so that
    it can still be used as an identifier outside of universe (but registering it
    as a token in a Term Syntax would not break the universe Parser). -/
def nonReservedSymbolFnAux (sym : String) (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.nonReservedSymbolFn
code: def nonReservedSymbolFn (sym : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.nonReservedSymbolInfo
code: def nonReservedSymbolInfo (sym : String) (includeIdent : Bool) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.nonReservedSymbolNoAntiquot
code: def nonReservedSymbolNoAntiquot (sym : String) (includeIdent := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.strAux
code: partial def strAux (sym : String) (errorMsg : String) (j : String.Pos) :ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.strAux.parse
code: partial def strAux (sym : String) (errorMsg : String) (j : String.Pos) :ParserFn 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.checkTailWs
code: def checkTailWs (prev : Syntax) : Bool 
goal: Bool

full_name: Lean.Parser.checkWsBeforeFn
code: def checkWsBeforeFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkWsBefore
code: /-- The `ws` parser requires that there is some whitespace at this location.
For example, the parser `"foo" ws "+"` parses `foo +` or `foo/- -/+` but not `foo+`.

This parser has arity 0 - it does not capture anything. -/
def checkWsBefore (errorMsg : String := "space before") : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkTailLinebreak
code: def checkTailLinebreak (prev : Syntax) : Bool 
goal: Bool

full_name: Lean.Parser.checkLinebreakBeforeFn
code: def checkLinebreakBeforeFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkLinebreakBefore
code: /-- The `linebreak` parser requires that there is at least one line break at this location.
(The line break may be inside a comment.)

This parser has arity 0 - it does not capture anything. -/
def checkLinebreakBefore (errorMsg : String := "line break") : Parser 
goal: Lean.Parser.Parser

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.pickNonNone
code: private def pickNonNone (stack : SyntaxStack) : Syntax 
goal: Lean.Syntax

full_name: Lean.Parser.checkNoWsBeforeFn
code: def checkNoWsBeforeFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkNoWsBefore
code: /-- The `noWs` parser requires that there is *no* whitespace between the preceding and following
parsers. For example, the parser `"foo" noWs "+"` parses `foo+` but not `foo +`.

This is almost the same as `"foo+"`, but using this parser will make `foo+` a token, which may cause
problems for the use of `"foo"` and `"+"` as separate tokens in other parsers.

This parser has arity 0 - it does not capture anything. -/
def checkNoWsBefore (errorMsg : String := "no space before") : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.unicodeSymbolFnAux
code: def unicodeSymbolFnAux (sym asciiSym : String) (expected : List String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.unicodeSymbolInfo
code: def unicodeSymbolInfo (sym asciiSym : String) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.unicodeSymbolFn
code: def unicodeSymbolFn (sym asciiSym : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.unicodeSymbolNoAntiquot
code: def unicodeSymbolNoAntiquot (sym asciiSym : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.mkAtomicInfo
code: def mkAtomicInfo (k : String) : ParserInfo 
goal: Lean.Parser.ParserInfo

full_name: Lean.Parser.expectTokenFn
code: /--
  Parses a token and asserts the result is of the given kind.
  `desc` is used in error messages as the token kind. -/
def expectTokenFn (k : SyntaxNodeKind) (desc : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.numLitFn
code: def numLitFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.numLitNoAntiquot
code: def numLitNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.scientificLitFn
code: def scientificLitFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.scientificLitNoAntiquot
code: def scientificLitNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.strLitFn
code: def strLitFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.strLitNoAntiquot
code: def strLitNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.charLitFn
code: def charLitFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.charLitNoAntiquot
code: def charLitNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.nameLitFn
code: def nameLitFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.nameLitNoAntiquot
code: def nameLitNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.identFn
code: def identFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.identNoAntiquot
code: def identNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.rawIdentNoAntiquot
code: def rawIdentNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.identEqFn
code: def identEqFn (id : Name) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.identEq
code: def identEq (id : Name) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.hygieneInfoFn
code: def hygieneInfoFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.hygieneInfoNoAntiquot
code: def hygieneInfoNoAntiquot : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.ParserState.keepTop
code: def keepTop (s : SyntaxStack) (startStackSize : Nat) : SyntaxStack 
goal: Lean.Parser.SyntaxStack

full_name: Lean.Parser.ParserState.keepNewError
code: def keepNewError (s : ParserState) (oldStackSize : Nat) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.ParserState.keepPrevError
code: def keepPrevError (s : ParserState) (oldStackSize : Nat) (oldStopPos : String.Pos) (oldError : Option Error) (oldLhsPrec : Nat) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.ParserState.mergeErrors
code: def mergeErrors (s : ParserState) (oldStackSize : Nat) (oldError : Error) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.ParserState.keepLatest
code: def keepLatest (s : ParserState) (startStackSize : Nat) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.ParserState.replaceLongest
code: def replaceLongest (s : ParserState) (startStackSize : Nat) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.invalidLongestMatchParser
code: def invalidLongestMatchParser (s : ParserState) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.runLongestMatchParser
code: /--
 Auxiliary function used to execute parsers provided to `longestMatchFn`.
 Push `left?` into the stack if it is not `none`, and execute `p`.

 Remark: `p` must produce exactly one syntax node.
 Remark: the `left?` is not none when we are processing trailing parsers. -/
def runLongestMatchParser (left? : Option Syntax) (startLhsPrec : Nat) (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.longestMatchStep
code: def longestMatchStep (left? : Option Syntax) (startSize startLhsPrec : Nat) (startPos : String.Pos) (prevPrio : Nat) (prio : Nat) (p : ParserFn)
    : ParserContext → ParserState → ParserState × Nat 
goal: Lean.Parser.ParserContext → Lean.Parser.ParserState → Lean.Parser.ParserState × Nat

full_name: Lean.Parser.longestMatchMkResult
code: def longestMatchMkResult (startSize : Nat) (s : ParserState) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.longestMatchFnAux.parse
code: def longestMatchFnAux (left? : Option Syntax) (startSize startLhsPrec : Nat) (startPos : String.Pos) (prevPrio : Nat) (ps : List (Parser × Nat)) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.longestMatchFnAux
code: def longestMatchFnAux (left? : Option Syntax) (startSize startLhsPrec : Nat) (startPos : String.Pos) (prevPrio : Nat) (ps : List (Parser × Nat)) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.longestMatchFn
code: def longestMatchFn (left? : Option Syntax) : List (Parser × Nat) → ParserFn
  
goal: List (Lean.Parser.Parser × Nat) → Lean.Parser.ParserFn

full_name: Lean.Parser.anyOfFn
code: def anyOfFn : List Parser → ParserFn
  
goal: List Lean.Parser.Parser → Lean.Parser.ParserFn

full_name: Lean.Parser.checkColEqFn
code: def checkColEqFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkColEq
code: /-- The `colEq` parser ensures that the next token starts at exactly the column of the saved
position (see `withPosition`). This can be used to do whitespace sensitive syntax like
a `by` block or `do` block, where all the lines have to line up.

This parser has arity 0 - it does not capture anything. -/
def checkColEq (errorMsg : String := "checkColEq") : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkColGeFn
code: def checkColGeFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkColGe
code: /-- The `colGe` parser requires that the next token starts from at least the column of the saved
position (see `withPosition`), but allows it to be more indented.
This can be used for whitespace sensitive syntax to ensure that a block does not go outside a
certain indentation scope. For example it is used in the lean grammar for `else if`, to ensure
that the `else` is not less indented than the `if` it matches with.

This parser has arity 0 - it does not capture anything. -/
def checkColGe (errorMsg : String := "checkColGe") : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkColGtFn
code: def checkColGtFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkColGt
code: /-- The `colGt` parser requires that the next token starts a strictly greater column than the saved
position (see `withPosition`). This can be used for whitespace sensitive syntax for the arguments
to a tactic, to ensure that the following tactic is not interpreted as an argument.
```
example (x : False) : False := by
  revert x
  exact id
```
Here, the `revert` tactic is followed by a list of `colGt ident`, because otherwise it would
interpret `exact` as an identifier and try to revert a variable named `exact`.

This parser has arity 0 - it does not capture anything. -/
def checkColGt (errorMsg : String := "checkColGt") : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkLineEqFn
code: def checkLineEqFn (errorMsg : String) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.checkLineEq
code: /-- The `lineEq` parser requires that the current token is on the same line as the saved position
(see `withPosition`). This can be used to ensure that composite tokens are not "broken up" across
different lines. For example, `else if` is parsed using `lineEq` to ensure that the two tokens
are on the same line.

This parser has arity 0 - it does not capture anything. -/
def checkLineEq (errorMsg : String := "checkLineEq") : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withPosition
code: /-- `withPosition(p)` runs `p` while setting the "saved position" to the current position.
This has no effect on its own, but various other parsers access this position to achieve some
composite effect:

* `colGt`, `colGe`, `colEq` compare the column of the saved position to the current position,
  used to implement Python-style indentation sensitive blocks
* `lineEq` ensures that the current position is still on the same line as the saved position,
  used to implement composite tokens

The saved position is only available in the read-only state, which is why this is a scoping parser:
after the `withPosition(..)` block the saved position will be restored to its original value.

This parser has the same arity as `p` - it just forwards the results of `p`. -/
def withPosition : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.withPositionAfterLinebreak
code: def withPositionAfterLinebreak : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.withoutPosition
code: /-- `withoutPosition(p)` runs `p` without the saved position, meaning that position-checking
parsers like `colGt` will have no effect. This is usually used by bracketing constructs like
`(...)` so that the user can locally override whitespace sensitivity.

This parser has the same arity as `p` - it just forwards the results of `p`. -/
def withoutPosition (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withForbidden
code: /-- `withForbidden tk p` runs `p` with `tk` as a "forbidden token". This means that if the token
appears anywhere in `p` (unless it is nested in `withoutForbidden`), parsing will immediately
stop there, making `tk` effectively a lowest-precedence operator. This is used for parsers like
`for x in arr do ...`: `arr` is parsed as `withForbidden "do" term` because otherwise `arr do ...`
would be treated as an application.

This parser has the same arity as `p` - it just forwards the results of `p`. -/
def withForbidden (tk : Token) (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withoutForbidden
code: /-- `withoutForbidden(p)` runs `p` disabling the "forbidden token" (see `withForbidden`), if any.
This is usually used by bracketing constructs like `(...)` because there is no parsing ambiguity
inside these nested constructs.

This parser has the same arity as `p` - it just forwards the results of `p`. -/
def withoutForbidden (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.eoiFn
code: def eoiFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.eoi
code: def eoi : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.TokenMap
code: /-- A multimap indexed by tokens. Used for indexing parsers by their leading token. -/
def TokenMap (α : Type) 
goal: Type

full_name: Lean.Parser.TokenMap.insert
code: def insert (map : TokenMap α) (k : Name) (v : α) : TokenMap α 
goal: Lean.Parser.TokenMap α

full_name: Lean.Parser.TokenMap.instInhabited
code: instance : Inhabited (TokenMap α) 
goal: Inhabited (Lean.Parser.TokenMap α)

full_name: Lean.Parser.TokenMap.instEmptyCollection
code: instance : EmptyCollection (TokenMap α) 
goal: EmptyCollection (Lean.Parser.TokenMap α)

full_name: Lean.Parser.TokenMap.instForInProdNameList
code: instance : ForIn m (TokenMap α) (Name × List α) 
goal: ForIn m (Lean.Parser.TokenMap α) (Lean.Name × List α)

full_name: Lean.Parser.PrattParsingTables.leadingParsers
code: structure PrattParsingTables where
  leadingTable    : TokenMap (Parser × Nat) := {}
  leadingParsers  : List (Parser × Nat) := [] -- for supporting parsers we cannot obtain first token
  trailingTable   : TokenMap (Parser × Nat) := {}
  trailingParsers : List (Parser × Nat) := []
goal: List (Lean.Parser.Parser × Nat)

full_name: Lean.Parser.PrattParsingTables.leadingTable
code: structure PrattParsingTables where
  leadingTable    : TokenMap (Parser × Nat) := {}
  leadingParsers  : List (Parser × Nat) := [] -- for supporting parsers we cannot obtain first token
  trailingTable   : TokenMap (Parser × Nat) := {}
  trailingParsers : List (Parser × Nat) := []
goal: Lean.Parser.TokenMap (Lean.Parser.Parser × Nat)

full_name: Lean.Parser.PrattParsingTables
code: structure PrattParsingTables where
  leadingTable    : TokenMap (Parser × Nat) := {}
  leadingParsers  : List (Parser × Nat) := [] -- for supporting parsers we cannot obtain first token
  trailingTable   : TokenMap (Parser × Nat) := {}
  trailingParsers : List (Parser × Nat) := []
goal: Type

full_name: Lean.Parser.PrattParsingTables.trailingTable
code: structure PrattParsingTables where
  leadingTable    : TokenMap (Parser × Nat) := {}
  leadingParsers  : List (Parser × Nat) := [] -- for supporting parsers we cannot obtain first token
  trailingTable   : TokenMap (Parser × Nat) := {}
  trailingParsers : List (Parser × Nat) := []
goal: Lean.Parser.TokenMap (Lean.Parser.Parser × Nat)

full_name: Lean.Parser.PrattParsingTables.trailingParsers
code: structure PrattParsingTables where
  leadingTable    : TokenMap (Parser × Nat) := {}
  leadingParsers  : List (Parser × Nat) := [] -- for supporting parsers we cannot obtain first token
  trailingTable   : TokenMap (Parser × Nat) := {}
  trailingParsers : List (Parser × Nat) := []
goal: List (Lean.Parser.Parser × Nat)

full_name: Lean.Parser.instInhabitedPrattParsingTables
code: instance : Inhabited PrattParsingTables 
goal: Inhabited Lean.Parser.PrattParsingTables

full_name: Lean.Parser.LeadingIdentBehavior.both
code: /--
  The type `LeadingIdentBehavior` specifies how the parsing table
  lookup function behaves for identifiers.  The function `prattParser`
  uses two tables `leadingTable` and `trailingTable`. They map tokens
  to parsers.

  We use `LeadingIdentBehavior.symbol` and `LeadingIdentBehavior.both`
  and `nonReservedSymbol` parser to implement the `tactic` parsers.
  The idea is to avoid creating a reserved symbol for each
  builtin tactic (e.g., `apply`, `assumption`, etc.).  That is, users
  may still use these symbols as identifiers (e.g., naming a
  function).
-/
inductive LeadingIdentBehavior where
  /-- `LeadingIdentBehavior.default`: if the leading token
  is an identifier, then `prattParser` just executes the parsers
  associated with the auxiliary token "ident". -/
  | default
  /-- `LeadingIdentBehavior.symbol`: if the leading token is
  an identifier `<foo>`, and there are parsers `P` associated with
  the token `<foo>`, then it executes `P`. Otherwise, it executes
  only the parsers associated with the auxiliary token "ident". -/
  | symbol
  /-- `LeadingIdentBehavior.both`: if the leading token
  an identifier `<foo>`, the it executes the parsers associated
  with token `<foo>` and parsers associated with the auxiliary
  token "ident". -/
  | both
  deriving Inhabited, BEq, Repr
goal: Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.LeadingIdentBehavior.default
code: /--
  The type `LeadingIdentBehavior` specifies how the parsing table
  lookup function behaves for identifiers.  The function `prattParser`
  uses two tables `leadingTable` and `trailingTable`. They map tokens
  to parsers.

  We use `LeadingIdentBehavior.symbol` and `LeadingIdentBehavior.both`
  and `nonReservedSymbol` parser to implement the `tactic` parsers.
  The idea is to avoid creating a reserved symbol for each
  builtin tactic (e.g., `apply`, `assumption`, etc.).  That is, users
  may still use these symbols as identifiers (e.g., naming a
  function).
-/
inductive LeadingIdentBehavior where
  /-- `LeadingIdentBehavior.default`: if the leading token
  is an identifier, then `prattParser` just executes the parsers
  associated with the auxiliary token "ident". -/
  | default
  /-- `LeadingIdentBehavior.symbol`: if the leading token is
  an identifier `<foo>`, and there are parsers `P` associated with
  the token `<foo>`, then it executes `P`. Otherwise, it executes
  only the parsers associated with the auxiliary token "ident". -/
  | symbol
  /-- `LeadingIdentBehavior.both`: if the leading token
  an identifier `<foo>`, the it executes the parsers associated
  with token `<foo>` and parsers associated with the auxiliary
  token "ident". -/
  | both
  deriving Inhabited, BEq, Repr
goal: Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.instInhabitedLeadingIdentBehavior
code: /--
  The type `LeadingIdentBehavior` specifies how the parsing table
  lookup function behaves for identifiers.  The function `prattParser`
  uses two tables `leadingTable` and `trailingTable`. They map tokens
  to parsers.

  We use `LeadingIdentBehavior.symbol` and `LeadingIdentBehavior.both`
  and `nonReservedSymbol` parser to implement the `tactic` parsers.
  The idea is to avoid creating a reserved symbol for each
  builtin tactic (e.g., `apply`, `assumption`, etc.).  That is, users
  may still use these symbols as identifiers (e.g., naming a
  function).
-/
inductive LeadingIdentBehavior where
  /-- `LeadingIdentBehavior.default`: if the leading token
  is an identifier, then `prattParser` just executes the parsers
  associated with the auxiliary token "ident". -/
  | default
  /-- `LeadingIdentBehavior.symbol`: if the leading token is
  an identifier `<foo>`, and there are parsers `P` associated with
  the token `<foo>`, then it executes `P`. Otherwise, it executes
  only the parsers associated with the auxiliary token "ident". -/
  | symbol
  /-- `LeadingIdentBehavior.both`: if the leading token
  an identifier `<foo>`, the it executes the parsers associated
  with token `<foo>` and parsers associated with the auxiliary
  token "ident". -/
  | both
  deriving Inhabited, BEq, Repr
goal: Inhabited Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.LeadingIdentBehavior.symbol
code: /--
  The type `LeadingIdentBehavior` specifies how the parsing table
  lookup function behaves for identifiers.  The function `prattParser`
  uses two tables `leadingTable` and `trailingTable`. They map tokens
  to parsers.

  We use `LeadingIdentBehavior.symbol` and `LeadingIdentBehavior.both`
  and `nonReservedSymbol` parser to implement the `tactic` parsers.
  The idea is to avoid creating a reserved symbol for each
  builtin tactic (e.g., `apply`, `assumption`, etc.).  That is, users
  may still use these symbols as identifiers (e.g., naming a
  function).
-/
inductive LeadingIdentBehavior where
  /-- `LeadingIdentBehavior.default`: if the leading token
  is an identifier, then `prattParser` just executes the parsers
  associated with the auxiliary token "ident". -/
  | default
  /-- `LeadingIdentBehavior.symbol`: if the leading token is
  an identifier `<foo>`, and there are parsers `P` associated with
  the token `<foo>`, then it executes `P`. Otherwise, it executes
  only the parsers associated with the auxiliary token "ident". -/
  | symbol
  /-- `LeadingIdentBehavior.both`: if the leading token
  an identifier `<foo>`, the it executes the parsers associated
  with token `<foo>` and parsers associated with the auxiliary
  token "ident". -/
  | both
  deriving Inhabited, BEq, Repr
goal: Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.LeadingIdentBehavior
code: /--
  The type `LeadingIdentBehavior` specifies how the parsing table
  lookup function behaves for identifiers.  The function `prattParser`
  uses two tables `leadingTable` and `trailingTable`. They map tokens
  to parsers.

  We use `LeadingIdentBehavior.symbol` and `LeadingIdentBehavior.both`
  and `nonReservedSymbol` parser to implement the `tactic` parsers.
  The idea is to avoid creating a reserved symbol for each
  builtin tactic (e.g., `apply`, `assumption`, etc.).  That is, users
  may still use these symbols as identifiers (e.g., naming a
  function).
-/
inductive LeadingIdentBehavior where
  /-- `LeadingIdentBehavior.default`: if the leading token
  is an identifier, then `prattParser` just executes the parsers
  associated with the auxiliary token "ident". -/
  | default
  /-- `LeadingIdentBehavior.symbol`: if the leading token is
  an identifier `<foo>`, and there are parsers `P` associated with
  the token `<foo>`, then it executes `P`. Otherwise, it executes
  only the parsers associated with the auxiliary token "ident". -/
  | symbol
  /-- `LeadingIdentBehavior.both`: if the leading token
  an identifier `<foo>`, the it executes the parsers associated
  with token `<foo>` and parsers associated with the auxiliary
  token "ident". -/
  | both
  deriving Inhabited, BEq, Repr
goal: Type

full_name: Lean.Parser.instReprLeadingIdentBehavior
code: /--
  The type `LeadingIdentBehavior` specifies how the parsing table
  lookup function behaves for identifiers.  The function `prattParser`
  uses two tables `leadingTable` and `trailingTable`. They map tokens
  to parsers.

  We use `LeadingIdentBehavior.symbol` and `LeadingIdentBehavior.both`
  and `nonReservedSymbol` parser to implement the `tactic` parsers.
  The idea is to avoid creating a reserved symbol for each
  builtin tactic (e.g., `apply`, `assumption`, etc.).  That is, users
  may still use these symbols as identifiers (e.g., naming a
  function).
-/
inductive LeadingIdentBehavior where
  /-- `LeadingIdentBehavior.default`: if the leading token
  is an identifier, then `prattParser` just executes the parsers
  associated with the auxiliary token "ident". -/
  | default
  /-- `LeadingIdentBehavior.symbol`: if the leading token is
  an identifier `<foo>`, and there are parsers `P` associated with
  the token `<foo>`, then it executes `P`. Otherwise, it executes
  only the parsers associated with the auxiliary token "ident". -/
  | symbol
  /-- `LeadingIdentBehavior.both`: if the leading token
  an identifier `<foo>`, the it executes the parsers associated
  with token `<foo>` and parsers associated with the auxiliary
  token "ident". -/
  | both
  deriving Inhabited, BEq, Repr
goal: Repr Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.instBEqLeadingIdentBehavior
code: BEq
goal: BEq Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.ParserCategory.kinds
code: /--
  Each parser category is implemented using a Pratt's parser.
  The system comes equipped with the following categories: `level`, `term`, `tactic`, and `command`.
  Users and plugins may define extra categories.

  The method
  ```
  categoryParser `term prec
  ```
  executes the Pratt's parser for category `term` with precedence `prec`.
  That is, only parsers with precedence at least `prec` are considered.
  The method `termParser prec` is equivalent to the method above.
-/
structure ParserCategory where
  /-- The name of a declaration which will be used as the target of
  go-to-definition queries and from which doc strings will be extracted.
  This is a dummy declaration of type `Lean.Parser.Category`
  created by `declare_syntax_cat`, but for builtin categories the declaration
  is made manually and passed to `registerBuiltinParserAttribute`. -/
  declName : Name
  /-- The list of syntax nodes that can parse into this category.
  This can be used to list all syntaxes in the category. -/
  kinds    : SyntaxNodeKindSet := {}
  /-- The parsing tables, which consist of a dynamic set of parser
  functions based on the syntaxes that have been declared so far. -/
  tables   : PrattParsingTables := {}
  /-- The `LeadingIdentBehavior`, which specifies how the parsing table
  lookup function behaves for the first identifier to be parsed.
  This is used by the `tactic` parser to avoid creating a reserved
  symbol for each builtin tactic (e.g., `apply`, `assumption`, etc.). -/
  behavior : LeadingIdentBehavior
  deriving Inhabited
goal: Lean.Parser.SyntaxNodeKindSet

full_name: Lean.Parser.instInhabitedParserCategory
code: /--
  Each parser category is implemented using a Pratt's parser.
  The system comes equipped with the following categories: `level`, `term`, `tactic`, and `command`.
  Users and plugins may define extra categories.

  The method
  ```
  categoryParser `term prec
  ```
  executes the Pratt's parser for category `term` with precedence `prec`.
  That is, only parsers with precedence at least `prec` are considered.
  The method `termParser prec` is equivalent to the method above.
-/
structure ParserCategory where
  /-- The name of a declaration which will be used as the target of
  go-to-definition queries and from which doc strings will be extracted.
  This is a dummy declaration of type `Lean.Parser.Category`
  created by `declare_syntax_cat`, but for builtin categories the declaration
  is made manually and passed to `registerBuiltinParserAttribute`. -/
  declName : Name
  /-- The list of syntax nodes that can parse into this category.
  This can be used to list all syntaxes in the category. -/
  kinds    : SyntaxNodeKindSet := {}
  /-- The parsing tables, which consist of a dynamic set of parser
  functions based on the syntaxes that have been declared so far. -/
  tables   : PrattParsingTables := {}
  /-- The `LeadingIdentBehavior`, which specifies how the parsing table
  lookup function behaves for the first identifier to be parsed.
  This is used by the `tactic` parser to avoid creating a reserved
  symbol for each builtin tactic (e.g., `apply`, `assumption`, etc.). -/
  behavior : LeadingIdentBehavior
  deriving Inhabited
goal: Inhabited Lean.Parser.ParserCategory

full_name: Lean.Parser.ParserCategory.behavior
code: /--
  Each parser category is implemented using a Pratt's parser.
  The system comes equipped with the following categories: `level`, `term`, `tactic`, and `command`.
  Users and plugins may define extra categories.

  The method
  ```
  categoryParser `term prec
  ```
  executes the Pratt's parser for category `term` with precedence `prec`.
  That is, only parsers with precedence at least `prec` are considered.
  The method `termParser prec` is equivalent to the method above.
-/
structure ParserCategory where
  /-- The name of a declaration which will be used as the target of
  go-to-definition queries and from which doc strings will be extracted.
  This is a dummy declaration of type `Lean.Parser.Category`
  created by `declare_syntax_cat`, but for builtin categories the declaration
  is made manually and passed to `registerBuiltinParserAttribute`. -/
  declName : Name
  /-- The list of syntax nodes that can parse into this category.
  This can be used to list all syntaxes in the category. -/
  kinds    : SyntaxNodeKindSet := {}
  /-- The parsing tables, which consist of a dynamic set of parser
  functions based on the syntaxes that have been declared so far. -/
  tables   : PrattParsingTables := {}
  /-- The `LeadingIdentBehavior`, which specifies how the parsing table
  lookup function behaves for the first identifier to be parsed.
  This is used by the `tactic` parser to avoid creating a reserved
  symbol for each builtin tactic (e.g., `apply`, `assumption`, etc.). -/
  behavior : LeadingIdentBehavior
  deriving Inhabited
goal: Lean.Parser.LeadingIdentBehavior

full_name: Lean.Parser.ParserCategory.declName
code: /--
  Each parser category is implemented using a Pratt's parser.
  The system comes equipped with the following categories: `level`, `term`, `tactic`, and `command`.
  Users and plugins may define extra categories.

  The method
  ```
  categoryParser `term prec
  ```
  executes the Pratt's parser for category `term` with precedence `prec`.
  That is, only parsers with precedence at least `prec` are considered.
  The method `termParser prec` is equivalent to the method above.
-/
structure ParserCategory where
  /-- The name of a declaration which will be used as the target of
  go-to-definition queries and from which doc strings will be extracted.
  This is a dummy declaration of type `Lean.Parser.Category`
  created by `declare_syntax_cat`, but for builtin categories the declaration
  is made manually and passed to `registerBuiltinParserAttribute`. -/
  declName : Name
  /-- The list of syntax nodes that can parse into this category.
  This can be used to list all syntaxes in the category. -/
  kinds    : SyntaxNodeKindSet := {}
  /-- The parsing tables, which consist of a dynamic set of parser
  functions based on the syntaxes that have been declared so far. -/
  tables   : PrattParsingTables := {}
  /-- The `LeadingIdentBehavior`, which specifies how the parsing table
  lookup function behaves for the first identifier to be parsed.
  This is used by the `tactic` parser to avoid creating a reserved
  symbol for each builtin tactic (e.g., `apply`, `assumption`, etc.). -/
  behavior : LeadingIdentBehavior
  deriving Inhabited
goal: Lean.Name

full_name: Lean.Parser.ParserCategory.tables
code: /--
  Each parser category is implemented using a Pratt's parser.
  The system comes equipped with the following categories: `level`, `term`, `tactic`, and `command`.
  Users and plugins may define extra categories.

  The method
  ```
  categoryParser `term prec
  ```
  executes the Pratt's parser for category `term` with precedence `prec`.
  That is, only parsers with precedence at least `prec` are considered.
  The method `termParser prec` is equivalent to the method above.
-/
structure ParserCategory where
  /-- The name of a declaration which will be used as the target of
  go-to-definition queries and from which doc strings will be extracted.
  This is a dummy declaration of type `Lean.Parser.Category`
  created by `declare_syntax_cat`, but for builtin categories the declaration
  is made manually and passed to `registerBuiltinParserAttribute`. -/
  declName : Name
  /-- The list of syntax nodes that can parse into this category.
  This can be used to list all syntaxes in the category. -/
  kinds    : SyntaxNodeKindSet := {}
  /-- The parsing tables, which consist of a dynamic set of parser
  functions based on the syntaxes that have been declared so far. -/
  tables   : PrattParsingTables := {}
  /-- The `LeadingIdentBehavior`, which specifies how the parsing table
  lookup function behaves for the first identifier to be parsed.
  This is used by the `tactic` parser to avoid creating a reserved
  symbol for each builtin tactic (e.g., `apply`, `assumption`, etc.). -/
  behavior : LeadingIdentBehavior
  deriving Inhabited
goal: Lean.Parser.PrattParsingTables

full_name: Lean.Parser.ParserCategory
code: /--
  Each parser category is implemented using a Pratt's parser.
  The system comes equipped with the following categories: `level`, `term`, `tactic`, and `command`.
  Users and plugins may define extra categories.

  The method
  ```
  categoryParser `term prec
  ```
  executes the Pratt's parser for category `term` with precedence `prec`.
  That is, only parsers with precedence at least `prec` are considered.
  The method `termParser prec` is equivalent to the method above.
-/
structure ParserCategory where
  /-- The name of a declaration which will be used as the target of
  go-to-definition queries and from which doc strings will be extracted.
  This is a dummy declaration of type `Lean.Parser.Category`
  created by `declare_syntax_cat`, but for builtin categories the declaration
  is made manually and passed to `registerBuiltinParserAttribute`. -/
  declName : Name
  /-- The list of syntax nodes that can parse into this category.
  This can be used to list all syntaxes in the category. -/
  kinds    : SyntaxNodeKindSet := {}
  /-- The parsing tables, which consist of a dynamic set of parser
  functions based on the syntaxes that have been declared so far. -/
  tables   : PrattParsingTables := {}
  /-- The `LeadingIdentBehavior`, which specifies how the parsing table
  lookup function behaves for the first identifier to be parsed.
  This is used by the `tactic` parser to avoid creating a reserved
  symbol for each builtin tactic (e.g., `apply`, `assumption`, etc.). -/
  behavior : LeadingIdentBehavior
  deriving Inhabited
goal: Type

full_name: Lean.Parser.ParserCategories
code: abbrev ParserCategories 
goal: Type

full_name: Lean.Parser.indexed
code: def indexed {α : Type} (map : TokenMap α) (c : ParserContext) (s : ParserState) (behavior : LeadingIdentBehavior) : ParserState × List α 
goal: Lean.Parser.ParserState × List α

full_name: Lean.Parser.CategoryParserFn
code: abbrev CategoryParserFn 
goal: Type

full_name: Lean.Parser.categoryParserFnRef
code: builtin_initialize categoryParserFnRef : IO.Ref CategoryParserFn ← IO.mkRef fun (_ : Name) => whitespace
goal: IO.Ref Lean.Parser.CategoryParserFn

full_name: Lean.Parser.initFn._@..lake.packages.lean4.src.lean.Lean.Parser.Basic._hyg.9249
code: builtin_initialize categoryParserFnRef : IO.Ref CategoryParserFn ← IO.mkRef fun (_ : Name) => whitespace
goal: IO (IO.Ref Lean.Parser.CategoryParserFn)

full_name: Lean.Parser.categoryParserFnExtension
code: builtin_initialize categoryParserFnExtension : EnvExtension CategoryParserFn ← registerEnvExtension $ categoryParserFnRef.get
goal: Lean.EnvExtension Lean.Parser.CategoryParserFn

full_name: Lean.Parser.initFn._@..lake.packages.lean4.src.lean.Lean.Parser.Basic._hyg.9276
code: builtin_initialize categoryParserFnExtension : EnvExtension CategoryParserFn ← registerEnvExtension $ categoryParserFnRef.get
goal: IO (Lean.EnvExtension Lean.Parser.CategoryParserFn)

full_name: Lean.Parser.categoryParserFn
code: def categoryParserFn (catName : Name) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.categoryParser
code: def categoryParser (catName : Name) (prec : Nat) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.termParser
code: def termParser (prec : Nat := 0) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.checkNoImmediateColon
code: /-- Fail if previous token is immediately followed by ':'. -/
def checkNoImmediateColon : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.setExpectedFn
code: def setExpectedFn (expected : List String) (p : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.setExpected
code: def setExpected (expected : List String) : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.pushNone
code: def pushNone : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.antiquotNestedExpr
code: def antiquotNestedExpr : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.antiquotExpr
code: def antiquotExpr : Parser       
goal: Lean.Parser.Parser

full_name: Lean.Parser.tokenAntiquotFn
code: def tokenAntiquotFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.tokenWithAntiquot
code: def tokenWithAntiquot : Parser → Parser 
goal: Lean.Parser.Parser → Lean.Parser.Parser

full_name: Lean.Parser.symbol
code: def symbol (sym : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.«instCoeStringParser_.lake»
code: instance : Coe String Parser 
goal: Coe String Lean.Parser.Parser

full_name: Lean.Parser.nonReservedSymbol
code: def nonReservedSymbol (sym : String) (includeIdent := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.unicodeSymbol
code: def unicodeSymbol (sym asciiSym : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.mkAntiquot
code: /--
  Define parser for `$e` (if `anonymous == true`) and `$e:name`.
  `kind` is embedded in the antiquotation's kind, and checked at syntax `match` unless `isPseudoKind` is true.
  Antiquotations can be escaped as in `$$e`, which produces the syntax tree for `$e`. -/
def mkAntiquot (name : String) (kind : SyntaxNodeKind) (anonymous := true) (isPseudoKind := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withAntiquotFn
code: def withAntiquotFn (antiquotP p : ParserFn) (isCatAntiquot := false) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.withAntiquot
code: /-- Optimized version of `mkAntiquot ... <|> p`. -/
def withAntiquot (antiquotP p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withoutInfo
code: def withoutInfo (p : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.mkAntiquotSplice
code: /-- Parse `$[p]suffix`, e.g. `$[p],*`. -/
def mkAntiquotSplice (kind : SyntaxNodeKind) (p suffix : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.withAntiquotSuffixSpliceFn
code: private def withAntiquotSuffixSpliceFn (kind : SyntaxNodeKind) (suffix : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.withAntiquotSuffixSplice
code: /-- Parse `suffix` after an antiquotation, e.g. `$x,*`, and put both into a new node. -/
def withAntiquotSuffixSplice (kind : SyntaxNodeKind) (p suffix : Parser) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.withAntiquotSpliceAndSuffix
code: def withAntiquotSpliceAndSuffix (kind : SyntaxNodeKind) (p suffix : Parser) 
goal: Lean.Parser.Parser

full_name: Lean.Parser.nodeWithAntiquot
code: def nodeWithAntiquot (name : String) (kind : SyntaxNodeKind) (p : Parser) (anonymous := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.sepByElemParser
code: def sepByElemParser (p : Parser) (sep : String) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.sepBy
code: def sepBy (p : Parser) (sep : String) (psep : Parser := symbol sep) (allowTrailingSep : Bool := false) : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.sepBy1
code: def sepBy1 (p : Parser) (sep : String) (psep : Parser := symbol sep) (allowTrailingSep : Bool := false) : Parser 
goal: Lean.Parser.Parser

full_name: _private.«.lake».packages.lean4.src.lean.Lean.Parser.Basic.0.Lean.Parser.mkResult
code: private def mkResult (s : ParserState) (iniSz : Nat) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.leadingParserAux
code: def leadingParserAux (kind : Name) (tables : PrattParsingTables) (behavior : LeadingIdentBehavior) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.leadingParser
code: def leadingParser (kind : Name) (tables : PrattParsingTables) (behavior : LeadingIdentBehavior) (antiquotParser : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.trailingLoopStep
code: def trailingLoopStep (tables : PrattParsingTables) (left : Syntax) (ps : List (Parser × Nat)) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.trailingLoop
code: partial def trailingLoop (tables : PrattParsingTables) (c : ParserContext) (s : ParserState) : ParserState 
goal: Lean.Parser.ParserState

full_name: Lean.Parser.prattParser
code: /--

  Implements a variant of Pratt's algorithm. In Pratt's algorithms tokens have a right and left binding power.
  In our implementation, parsers have precedence instead. This method selects a parser (or more, via
  `longestMatchFn`) from `leadingTable` based on the current token. Note that the unindexed `leadingParsers` parsers
  are also tried. We have the unidexed `leadingParsers` because some parsers do not have a "first token". Example:
  ```
  syntax term:51 "≤" ident "<" term "|" term : index
  ```
  Example, in principle, the set of first tokens for this parser is any token that can start a term, but this set
  is always changing. Thus, this parsing rule is stored as an unindexed leading parser at `leadingParsers`.
  After processing the leading parser, we chain with parsers from `trailingTable`/`trailingParsers` that have precedence
  at least `c.prec` where `c` is the `ParsingContext`. Recall that `c.prec` is set by `categoryParser`.

  Note that in the original Pratt's algorithm, precedences are only checked before calling trailing parsers. In our
  implementation, leading *and* trailing parsers check the precedence. We claim our algorithm is more flexible,
  modular and easier to understand.

  `antiquotParser` should be a `mkAntiquot` parser (or always fail) and is tried before all other parsers.
  It should not be added to the regular leading parsers because it would heavily
  overlap with antiquotation parsers nested inside them. -/
def prattParser (kind : Name) (tables : PrattParsingTables) (behavior : LeadingIdentBehavior) (antiquotParser : ParserFn) : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.fieldIdxFn
code: def fieldIdxFn : ParserFn 
goal: Lean.Parser.ParserFn

full_name: Lean.Parser.fieldIdx
code: def fieldIdx : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Parser.skip
code: def skip : Parser 
goal: Lean.Parser.Parser

full_name: Lean.Syntax.foldArgsM
code: def foldArgsM (s : Syntax) (f : Syntax → β → m β) (b : β) : m β 
goal: m β

full_name: Lean.Syntax.foldArgs
code: def foldArgs (s : Syntax) (f : Syntax → β → β) (b : β) : β 
goal: β

full_name: Lean.Syntax.forArgsM
code: def forArgsM (s : Syntax) (f : Syntax → m Unit) : m Unit 
goal: m Unit