TY - GEN
T1 - Embedding Invertible Languages with Binders - A Case of the FliPpr Language
T2 - St. Louis, MO, USA — September 27 - 28, 2018
AU - Matsuda, Kazutaka
AU - Wang, Meng
PY - 2018
Y1 - 2018
N2 - This paper describes a new embedding technique of invertible programming languages, through the case of the FliPpr language. Embedded languages have the advantage of inheriting host languages' features and supports; and one of the influential methods of embedding is the tagless-final style, which enables a high level of programmability and extensibility. However, it is not straightforward to apply the method to the family of invertible/reversible/bidirectional languages, due to the different ways functions in such domains are represented. We consider FliPpr, an invertible pretty-printing system, as a representative of such languages, and show that Atkey et al.'s unembedding technique can be used to address the problem. Together with a reformulation of FliPpr, our embedding achieves a high level of interoperability with the host language Haskell, which is not found in any other invertible languages. We implement the idea and demonstrate the benefits of the approach with examples.
AB - This paper describes a new embedding technique of invertible programming languages, through the case of the FliPpr language. Embedded languages have the advantage of inheriting host languages' features and supports; and one of the influential methods of embedding is the tagless-final style, which enables a high level of programmability and extensibility. However, it is not straightforward to apply the method to the family of invertible/reversible/bidirectional languages, due to the different ways functions in such domains are represented. We consider FliPpr, an invertible pretty-printing system, as a representative of such languages, and show that Atkey et al.'s unembedding technique can be used to address the problem. Together with a reformulation of FliPpr, our embedding achieves a high level of interoperability with the host language Haskell, which is not found in any other invertible languages. We implement the idea and demonstrate the benefits of the approach with examples.
U2 - 10.1145/3242744.3242758
DO - 10.1145/3242744.3242758
M3 - Conference Contribution (Conference Proceeding)
SN - 9781450358354
T3 - ACM SIGPLAN Notices
SP - 158
EP - 171
BT - Haskell 2018 Proceedings of the 11th ACM SIGPLAN
PB - Association for Computing Machinery (ACM)
ER -