|
|
|
|
|
by ashton314
702 days ago
|
|
We are absolutely swimming in little languages. Consider these languages: - The language of regular expressions - SQL queries - In web frameworks, the language of routes - etc. Unfortunately we embed a lot of these languages as strings. This is problematic because the language usually sees just opaque strings—we can't apply any of our lovely static analysis tools to these little embedded languages. I'm doing some research in this area. We just got a paper published at ECOOP. The big idea is that, with a little bit of clever metaprogramming, we can help the type checker understand these little languages better and give us more helpful hints or execute more efficiently. This isn't a new idea, but no one has given it a name before. Here's the blog post version: https://lambdaland.org/posts/2024-07-15_type_tailoring/ (HN discussion): https://news.ycombinator.com/item?id=40990232 |
|
https://github.com/williamcotton/guish
It is an experiment in using *nix pipelines to put languages on an even footing and not just treat them as strings embedded in strings.
I guess take a look at the screenshot and animated GIF for a better idea of what it does!