paulstansifer / unseemly

Macros have types!
http://unseemly.github.io/
MIT License
129 stars 5 forks source link

Allow prelude languages, based on file extension #39

Open paulstansifer opened 3 years ago

paulstansifer commented 3 years ago

.≉ files will be the Unseemly core language, but we don't want to have to use some sort of import at the top of every other file just to allow comments and function definition. So, we'll create an (initially hardcoded) table mapping file extensions to languages.

In order to make this fast, we should serialize the language definitions to disk, rather than starting from scratch at startup every time.

Once this is done, I'd like to have .unpy for a Python-like language (implicitly-typed, significant indentation, list comprehensions), .unml for an ML-like language (but without H-M type inference, probably), and probably a third, simpler language for bootstrapping them from. (but that's not in the scope of this issue)