Skip to content

Latest commit

 

History

History
23 lines (15 loc) · 1.13 KB

Readme.md

File metadata and controls

23 lines (15 loc) · 1.13 KB

SCALL1ON

Overview

Scallion is a library for writing parsers and pretty printers for LL(1) languages in Scala.

Documentation

A comprehensive Scaladoc API is available online.

Parsing Algorithm

Scallion uses a novel parsing algorithm that we have described in the paper: LL(1) Parsing with Derivatives and Zippers. The algorithm has been formally proven correct in Coq.

Examples

  • JSON: This example showcases how to build a basic JSON lexer & parser using Scallion.
  • Lambda Calculus: This example shows how to get a pretty printer almost for free alongside your parser.
  • Calculator: This example shows how to use the operators combinator to easily handle operators with various associativities and priorities.
  • Roman Numerals: This example presents a simple parser and pretty printer for roman numerals.