z-logo
open-access-imgOpen Access
Gradually typed symbolic expressions
Author(s) -
David Broman,
Jeremy G. Siek
Publication year - 2017
Publication title -
kth publication database diva (kth royal institute of technology)
Language(s) - English
Resource type - Conference proceedings
ISBN - 978-1-4503-5587-2
DOI - 10.1145/3162068
Subject(s) - computer science , programming language , digital subscriber line , embedding , type inference , domain specific language , semantics (computer science) , theoretical computer science , symbolic execution , inference , artificial intelligence , telecommunications , software
Embedding a domain-specific language (DSL) in a general purpose host language is an efficient way to develop a new DSL. Various kinds of languages and paradigms can be used as host languages, including object-oriented, functional, statically typed, and dynamically typed variants, all having their pros and cons. For deep embedding, statically typed languages enable early checking and potentially good DSL error messages, instead of reporting runtime errors. Dynamically typed languages, on the other hand, enable flexible transformations, thus avoiding extensive boilerplate code. In this paper, we introduce the concept of gradually typed symbolic expressions that mix static and dynamic typing for symbolic data. The key idea is to combine the strengths of dynamic and static typing in the context of deep embedding of DSLs. We define a gradually typed calculus λ<⋆>, formalize its type system and dynamic semantics, and prove type safety. We introduce a host language called Modelyze that is based on λ<⋆>, and evaluate the approach by embedding a series of equation-based domain-specific modeling languages, all within the domain of physical modeling and simulation.

The content you want is available to Zendy users.

Already have an account? Click here to sign in.
Having issues? You can contact us here
Accelerating Research

Address

John Eccles House
Robert Robinson Avenue,
Oxford Science Park, Oxford
OX4 4GP, United Kingdom