Skip to content

Latest commit

 

History

History
41 lines (26 loc) · 987 Bytes

README.md

File metadata and controls

41 lines (26 loc) · 987 Bytes

incremental-play

Playing with incremental parsing and later compiler passes

First pass will be to build a haskell version of the approach from "Efficient and Flexible Incremental Parsing", https://pdfs.semanticscholar.org/4d22/fab95c78b3c23fa9dff88fb82976edc213c2.pdf

This is also implemented in https://github.com/tree-sitter/tree-sitter

To experiment

Install the custom version of happy from https://github.com/alanz/happy, using the incremental branch.

I rename the installed executable to happy-az, so that it does not interfere with the system version.

In this directory

make

Load app/Main.hs into ghci and run it

Emacs integration

First run stack install

(package-install 'lsp-mode)
(package-install 'lsp-ui)

(require 'lsp-ui)
(require 'lsp-mode)

(add-to-list 'load-path "/home/alanz/mysrc/github/alanz/incremental-play/elisp")
(require 'lsp-inc)

(add-hook 'inc-mode-hook #'lsp-inc-enable)
(add-hook 'inc-mode-hook 'flycheck-mode)