Higher-order Data Types à la Carte

Disclaimer: This post was translated into English by an AI model. It may contain mistakes or awkward wording. I recently needed to represent an AST for a small project, and I wanted the AST itself to be extensible: I could define fragments of a language and then combine them as needed. This sounds very suitable for DTALC. But one soon discovers that the classic DTALC formulation does not work.…