van Binsbergen, LT, Mosses, PD and Sculthorpe, N ORCID: https://orcid.org/0000-0002-7244-0916, 2019. Executable component-based semantics. Journal of Logical and Algebraic Methods in Programming, 103, pp. 184-212. ISSN 2352-2208
Preview |
Text
13181_Sculthorpe.pdf - Post-print Download (996kB) | Preview |
Abstract
The potential benefits of formal semantics are well known. However, a substantial amount of work is required to produce a complete and accurate formal semantics for a major language; and when the language evolves, large-scale revision of the semantics may be needed to reflect the changes. The investment of effort needed to produce an initial definition, and subsequently to revise it, has discouraged language developers from using formal semantics. Consequently, many major programming languages (and most domain-specific languages) do not yet have formal semantic definitions.
To improve the practicality of formal semantic definitions, the PLanCompS project has developed a component-based approach. In this approach, the semantics of a language is defined by translating its constructs (compositionally) to combinations of so-called fundamental constructs, or ‘funcons’. Each funcon is defined using a modular variant of Structural Operational Semantics, and forms a language-independent component that can be reused in definitions of different languages. A substantial library of funcons has been developed and tested in several case studies. Crucially, the definition of each funcon is fixed, and does not need changing when new funcons are added to the library.
For specifying component-based semantics, we have designed and implemented a meta-language called CBS. It includes specification of abstract syntax, of its translation to funcons, and of the funcons themselves. Development of CBS specifications is supported by an integrated development environment. The accuracy of a language definition can be tested by executing the specified translation on programs written in the defined language, and then executing the resulting funcon terms using an interpreter generated from the CBS definitions of the funcons. This paper gives an introduction to CBS, illustrates its use, and presents the various tools involved in our implementation of CBS.
Item Type: | Journal article |
---|---|
Publication Title: | Journal of Logical and Algebraic Methods in Programming |
Creators: | van Binsbergen, L.T., Mosses, P.D. and Sculthorpe, N. |
Publisher: | Elsevier |
Date: | 2019 |
Volume: | 103 |
ISSN: | 2352-2208 |
Identifiers: | Number Type 10.1016/j.jlamp.2018.12.004 DOI |
Divisions: | Schools > School of Science and Technology |
Record created by: | Jonathan Gallacher |
Date Added: | 24 Jan 2019 09:26 |
Last Modified: | 04 Jan 2020 03:00 |
URI: | https://irep.ntu.ac.uk/id/eprint/35667 |
Actions (login required)
Edit View |
Statistics
Views
Views per month over past year
Downloads
Downloads per month over past year