MoL-2016-18: Readtable-Macro Transducer-Chain Parsing

MoL-2016-18: Drumm, Eli (2016) Readtable-Macro Transducer-Chain Parsing. [Report]

[thumbnail of MoL-2016-18.pdf]
Preview
Text
MoL-2016-18.pdf

Download (870kB) | Preview

Abstract

While extending the semantics of programming languages is commonplace, extending their syntax is usually not possible. In this thesis, we are concerned with the problem of parsing programming languages that are simultaneously syntactically extensible and human-readable. The quintessential extensible programming language, Lisp, can be extended by two separate macro systems that allow user-defined syntactic features to be integrated naturally and directly into the parser. However, the default syntax of Lisp is notoriously unreadable. Other languages, such as Python, are highly readable, but are designed and parsed in ways that leave the syntax essentially frozen from the user’s perspective.
We will propose a new parsing method, called Readtable-Macro Transducer-Chain parsing, that is inspired by Lisp’s reader algorithm. This algorithm is naively extended to add support for readable syntactic structures (such as infix notation), while retaining the spirit of simplicity and modularity that is its characteristic.
As a proof-of-concept, we implement a compiler for a new programming language called Anoky — essentially an alternative syntax for Python.

Item Type: Report
Report Nr: MoL-2016-18
Series Name: Master of Logic Thesis (MoL) Series
Year: 2016
Subjects: Computation
Logic
Depositing User: Dr Marco Vervoort
Date Deposited: 27 Oct 2016 15:32
Last Modified: 27 Oct 2016 15:35
URI: https://eprints.illc.uva.nl/id/eprint/1406

Actions (login required)

View Item View Item