index page - awarm.space

The architecture of fancynote

Parsing

I have no idea what I'm doing here and so the pipeline for processing fancynote files is extremely ad-hoc.

  1. lexing : split the file into a series of consecutive tokens. Also insert tokens at particular points (newlines)
  2. parsing : turn those tokens into a tree structure
  3. running : run the code to generate html

Lexing and parsing are pretty straightforward. Running consists of

  1. step through the tree generated by the parser
  2. everytime you see a new node in the tree, check to see whether it's first item corresponds to a known function
  3. call that function with the node as input

Language and Syntax

The syntax for fancynote is an extremely vanilla lisp.

Language features include:

An example

##[ Parsing ] I have no idea what I'm doing here and so the pipeline for processing fancynote files is [i extremely] ad-hoc. [olist [- [b lexing]: split the file into a series of consecutive tokens. Also insert tokens at particular points (newlines)] [- [b parsing]: turn those tokens into a tree structure] [- [b running]: run the code to generate html]] Lexing and parsing are pretty straightforward. [i Running] consists of


This all will be changing extremely rapidly. Check in todos to see what is on the table.