ruminant

Crates.ioruminant
lib.rsruminant
version0.17.0
sourcesrc
created_at2023-06-15 02:35:43.895694
updated_at2023-09-29 14:28:06.034174
descriptionAn exploration into implementing parser combinators
homepage
repositoryhttps://gitlab.com/wake-sleeper/ruminant
max_upload_size
id890738
size20,914
Eze Anyanwu (eze-works)

documentation

README

ruminant, a parser combinator library

Deprecated See my latest stab at this: parser-compose

⚠️ Warning ☣️
Homemade, hand-rolled code ahead. Experimental. May not function as advertised.

This is an introduction by example. For a first-principles introduction to parser combinators see here.

  • A parser is a function that takes some input in, extracts some information and returns the result of this extraction. In order to make any progress, the result contains the leftover input after consuming some part of it, or in the case of error returns some value indicating failure.

  • A combinator takes one or more parsers as input and returns a different parser. They are useful for uhh...combining multiple parsers together or even changing what parsers do.

With only these two ideas the world becomes your oyster.

Examples coming sooon

Commit count: 51

cargo fmt