Abstract
A domain-specific language can be implemented by embedding within a general-purpose host language. This embedding may be deep or shallow, depending on whether terms in the language construct syntactic or semantic representations. The deep and shallow styles are closely related, and intimately connected to folds; in this paper, we explore that connection.
- Robert Atkey, Sam Lindley, and Jeremy Yallop. Unembedding domain-specific languages. In Haskell Symposium, pages 37--48. ACM, 2009. Google Scholar
Digital Library
- Lennart Augustsson. Making EDSLs fly. In TechMesh, London, December 2012. Video at http://vimeo.com/73223479.Google Scholar
- Richard S. Bird. The promotion and accumulation strategies in transformational programming. ACM Transactions on Programming Languages and Systems, 6(4):487--504, October 1984. Addendum in TOPLAS 7(3):490--492, July 1985. Google Scholar
Digital Library
- Corrado Böhm and Alessandro Berarducci. Automatic synthesis of typed λ-programs on term algebras. Theoretical Computer Science, 39:135--154, 1985.Google Scholar
Cross Ref
- Richard Boulton. Personal communication, 10th February 2014.Google Scholar
- Richard Boulton, Andrew Gordon, Mike Gordon, John Harrison, John Herbert, and John Van Tassel. Experience with embedding hardware description languages in HOL. In Victoria Stavridou, Thomas F. Melham, and Raymond T. Boute, editors, IFIP TC10/WG 10.2 International Conference on Theorem Provers in Circuit Design: Theory, Practice and Experience, pages 129--156. North-Holland/Elsevier, 1992. Google Scholar
Digital Library
- Richard P. Brent and Hsiang-Tsung Kung. The chip complexity of binary arithmetic. In Symposium on Theory of Computing, pages 190--200. ACM, 1980. Google Scholar
Digital Library
- Jacques Carette, Oleg Kiselyov, and Chung-chieh Shan. Finally tagless, partially evaluated: Tagless staged interpreters for simpler typed languages. Journal of Functional Programming, 19(5):509--543, 2009. Google Scholar
Digital Library
- Maarten M. Fokkinga. Tupling and mutumorphisms. The Squiggolist, 1(4):81--82, June 1990.Google Scholar
- Martin Fowler. Domain-Specific Languages. Addison-Wesley, 2011. Google Scholar
Digital Library
- Jeremy Gibbons. Functional programming for domain-specific languages. In Viktória Zsók, editor, Central European Functional Programming Summer School, volume 8606 of Lecture Notes in Computer Science, pages 1--27. Springer, 2014. To appear.Google Scholar
Cross Ref
- Jeremy Gibbons and Geraint Jones. The under-appreciated unfold. In International Conference on Functional Programming, pages 273--279, Baltimore, Maryland, September 1998. Google Scholar
Digital Library
- Ralf Hinze. An algebra of scans. In Mathematics of Program Construction, volume 3125 of Lecture Notes in Computer Science, pages 186--210. Springer, 2004.Google Scholar
Cross Ref
- Ralf Hinze. Church numerals, twice! Journal of Functional Programming, 15(1), 2005. Google Scholar
Digital Library
- Ralf Hinze. Adjoint folds and unfolds: An extended study. Science of Computer Programming, 78(11):2108--2159, 2013. Google Scholar
Digital Library
- Ralf Hinze, Nicolas Wu, and Jeremy Gibbons. Unifying structured recursion schemes. In International Conference on Functional Programming, pages 209--220, Boston, Massachusetts, September 2013. Google Scholar
Digital Library
- Zhenjiang Hu, Hideya Iwasaki, and Masato Takeichi. Formal derivation of efficient parallel programs by construction of list homomorphisms. ACM Transactions on Programming Languages and Systems, 19(3):444--461, 1997. Google Scholar
Digital Library
- Paul Hudak. Building domain-specific embedded languages. ACM Computing Surveys, 28(4), 1996. Google Scholar
Digital Library
- Anne Kaldewaij. Programming: The Derivation of Algorithms. Prentice Hall, 1990. Google Scholar
Digital Library
- Oleg Kiselyov. Typed tagless final interpreters. In Jeremy Gibbons, editor, Generic and Indexed Programming, volume 7470 of Lecture Notes in Computer Science, pages 130--174. Springer, 2012. Google Scholar
Digital Library
- Oleg Kiselyov, Amr Sabry, and Cameron Swords. Extensible effects: An alternative to monad transformers. In Haskell Symposium, pages 59--70. ACM, 2013. Google Scholar
Digital Library
- Shriram Krishnamurthi, Matthias Felleisen, and Daniel P. Friedman. Synthesizing object-oriented and functional design to promote re-use. In European Conference on Object-Oriented Programming, volume 1445 of Lecture Notes in Computer Science, pages 91--113. Springer, 1998. Google Scholar
Digital Library
- Ehud Lamm. CUFP write-up. Blog post, http://lambda-the-ultimate.org/node/2572, December 2007.Google Scholar
- Ralf Lämmel, Joost Visser, and Jan Kort. Dealing with large bananas. In Johan Jeuring, editor, Workshop on Generic Programming, volume Technical Report UU-CS-2000-19. Universiteit Utrecht, 2000.Google Scholar
- John Reynolds. User-defined types and procedural data structures as complementary approaches to data abstraction. In Stephen A. Schuman, editor, New Directions in Algorithmic Languages, pages 157--168, 1975.Google Scholar
- Josef Svenningsson and Emil Axelsson. Combining deep and shallow embedding for embedded domain-specific languages. In Trends in Functional Programming 2012, volume 7829 of Lecture Notes in Computer Science, pages 21--36, 2013.Google Scholar
- Wouter Swierstra. Datatypes à la carte. Journal of Functional Programming, 18(4):423--436, 2008. Google Scholar
Digital Library
- Philip Wadler. Theorems for free! In Functional Programming Languages and Computer Architecture, pages 347--359. ACM, 1989. Google Scholar
Digital Library
- Philip Wadler. The expression problem. Java Genericity Mailing list, November 1998. http://homepages.inf.ed.ac.uk/wadler/papers/expression/expression.txt.Google Scholar
- Philip Wadler and Stephen Blott. How to make ad-hoc polymorphism less ad hoc. In Principles of Programming Languages, pages 60--76. ACM, 1989. Google Scholar
Digital Library
Index Terms
Folding domain-specific languages: deep and shallow embeddings (functional Pearl)
Recommendations
Folding domain-specific languages: deep and shallow embeddings (functional Pearl)
ICFP '14: Proceedings of the 19th ACM SIGPLAN international conference on Functional programmingA domain-specific language can be implemented by embedding within a general-purpose host language. This embedding may be deep or shallow, depending on whether terms in the language construct syntactic or semantic representations. The deep and shallow ...
Unembedding domain-specific languages
Haskell '09: Proceedings of the 2nd ACM SIGPLAN symposium on HaskellHigher-order abstract syntax provides a convenient way of embedding domain-specific languages, but is awkward to analyse and manipulate directly. We explore the boundaries of higher-order abstract syntax. Our key tool is the unembedding of embedded ...
Development of internal domain-specific languages: design principles and design patterns
PLoP '11: Proceedings of the 18th Conference on Pattern Languages of ProgramsA great part of software development challenges can be solved by one universal tool: Abstraction. Developers solve development challenges by using expressions and concepts that abstract from too technical details. One especially supportive tool for ...







Comments