Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Show HN: How to write a tiny compiler. Parent comment
A clause consists of a '{', one or more key-value pairs, and a '}'.
A key-value pair consists of a string and a value.
A value is either a string or a clause.
Now turn each definition into a function.
Here's a nice-looking article from Googling for "writing a recursive descent parser": http://weblog.jamisbuck.org/2015/7/30/writing-a-simple-recur...
There are no comments on this comment yet.
A clause consists of a '{', one or more key-value pairs, and a '}'.
A key-value pair consists of a string and a value.
A value is either a string or a clause.
Now turn each definition into a function.
Here's a nice-looking article from Googling for "writing a recursive descent parser": http://weblog.jamisbuck.org/2015/7/30/writing-a-simple-recur...