(do-update-state f)
(do-update-state f arg)
This parser applies function f
to the parser state and returns nil
.
This parser applies function `f` to the parser state and returns `nil`.
This parser returns the current input.
This parser returns the current input.
This parser returns the full parser state as a 'State' record.
This parser returns the full parser state as a 'State' record.
This parser returns the current user state.
This parser returns the current user state.
(set-input input)
This parser continues parsing with input
.
This parser continues parsing with `input`.
(set-parser-state state)
This parser set the full parser state to state
.
This parser set the full parser state to `state`.
(set-user-state u)
This parser sets the user state to u
This parser sets the user state to `u`
(update-parser-state f)
This parser applies function f
to the parser state and returns modified
parser state.
This parser applies function `f` to the parser state and returns modified parser state.
(update-user-state f)
This parser applies function f
to the user state. Suppose that we want to
count identifiers in a source, we could use the user state as:
(bind-let [x identifier
_ (update-user-state inc)]
(result x))
This parser applies function `f` to the user state. Suppose that we want to count identifiers in a source, we could use the user state as: (bind-let [x identifier _ (update-user-state inc)] (result x))
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close