描述和检查程序设计语言的自然语义定义的工具

Georgian-Vlad Saioc, Hans Hüttel
{"title":"描述和检查程序设计语言的自然语义定义的工具","authors":"Georgian-Vlad Saioc, Hans Hüttel","doi":"10.4204/EPTCS.369.4","DOIUrl":null,"url":null,"abstract":"Many universities have courses and projects revolving around compiler or interpreter implementation as part of their degree programmes in computer science. In such teaching activities, tool support can be highly beneficial. While there are already several tools for assisting with development of the front end of compilers, tool support tapers off towards the back end, or requires more background experience than is expected of undergraduate students. Structural operational semantics is a useful and mathematically simple formalism for specifying the behaviour of programs and a specification lends itself well to implementation; in particular big-step or natural semantics is often a useful and simple approach. However, many students struggle with learning the notation and often come up with ill-defined and meaningless attempts at defining a structural operational semantics. A survey shows that students working on programming language projects feel that tool support is lacking and would be useful. Many of these problems encountered when developing a semantic definition are similar to problems encountered in programming, in particular ones that are essentially the result of type errors. We present a pedagogical metalanguage based on natural semantics, and its implementation, as an attempt to marry two notions: a syntax similar to textbook notation for natural semantics on the one hand, and automatic verification of some correctness properties on the other by means of a strong type discipline. The metalanguage and the tool provide the facilities for writing and executing specifications as a form of programming. The user can check that the specification is not meaningless as well as execute programs, if the specification makes sense.","PeriodicalId":9644,"journal":{"name":"Catalysis Surveys from Japan","volume":"87 10 1","pages":"51-66"},"PeriodicalIF":0.0000,"publicationDate":"2022-09-20","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"A Tool for Describing and Checking Natural Semantics Definitions of Programming Languages\",\"authors\":\"Georgian-Vlad Saioc, Hans Hüttel\",\"doi\":\"10.4204/EPTCS.369.4\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Many universities have courses and projects revolving around compiler or interpreter implementation as part of their degree programmes in computer science. In such teaching activities, tool support can be highly beneficial. While there are already several tools for assisting with development of the front end of compilers, tool support tapers off towards the back end, or requires more background experience than is expected of undergraduate students. Structural operational semantics is a useful and mathematically simple formalism for specifying the behaviour of programs and a specification lends itself well to implementation; in particular big-step or natural semantics is often a useful and simple approach. However, many students struggle with learning the notation and often come up with ill-defined and meaningless attempts at defining a structural operational semantics. A survey shows that students working on programming language projects feel that tool support is lacking and would be useful. Many of these problems encountered when developing a semantic definition are similar to problems encountered in programming, in particular ones that are essentially the result of type errors. We present a pedagogical metalanguage based on natural semantics, and its implementation, as an attempt to marry two notions: a syntax similar to textbook notation for natural semantics on the one hand, and automatic verification of some correctness properties on the other by means of a strong type discipline. The metalanguage and the tool provide the facilities for writing and executing specifications as a form of programming. The user can check that the specification is not meaningless as well as execute programs, if the specification makes sense.\",\"PeriodicalId\":9644,\"journal\":{\"name\":\"Catalysis Surveys from Japan\",\"volume\":\"87 10 1\",\"pages\":\"51-66\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2022-09-20\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Catalysis Surveys from Japan\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.4204/EPTCS.369.4\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Catalysis Surveys from Japan","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.4204/EPTCS.369.4","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

摘要

作为计算机科学学位课程的一部分,许多大学都有围绕编译器或解释器实现的课程和项目。在这样的教学活动中,工具支持是非常有益的。虽然已经有一些工具可以帮助开发编译器的前端,但工具支持逐渐减少到后端,或者需要比本科生更多的背景经验。结构操作语义是一种有用且数学上简单的形式,用于指定程序的行为,并且规范本身很适合实现;特别是大步骤或自然语义通常是一种有用且简单的方法。然而,许多学生在学习符号时遇到了困难,并且经常在定义结构操作语义时提出定义不明确和无意义的尝试。一项调查显示,从事编程语言项目的学生认为缺乏工具支持,而工具支持是有用的。在开发语义定义时遇到的许多问题与编程中遇到的问题类似,特别是那些本质上是类型错误造成的问题。我们提出了一种基于自然语义的教学元语言及其实现,试图将两个概念结合在一起:一方面是类似于自然语义教科书符号的语法,另一方面是通过强类型学科对某些正确性属性进行自动验证。元语言和工具为编写和执行规范作为一种编程形式提供了便利。如果规范有意义,用户可以检查规范是否无意义,也可以执行程序。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
A Tool for Describing and Checking Natural Semantics Definitions of Programming Languages
Many universities have courses and projects revolving around compiler or interpreter implementation as part of their degree programmes in computer science. In such teaching activities, tool support can be highly beneficial. While there are already several tools for assisting with development of the front end of compilers, tool support tapers off towards the back end, or requires more background experience than is expected of undergraduate students. Structural operational semantics is a useful and mathematically simple formalism for specifying the behaviour of programs and a specification lends itself well to implementation; in particular big-step or natural semantics is often a useful and simple approach. However, many students struggle with learning the notation and often come up with ill-defined and meaningless attempts at defining a structural operational semantics. A survey shows that students working on programming language projects feel that tool support is lacking and would be useful. Many of these problems encountered when developing a semantic definition are similar to problems encountered in programming, in particular ones that are essentially the result of type errors. We present a pedagogical metalanguage based on natural semantics, and its implementation, as an attempt to marry two notions: a syntax similar to textbook notation for natural semantics on the one hand, and automatic verification of some correctness properties on the other by means of a strong type discipline. The metalanguage and the tool provide the facilities for writing and executing specifications as a form of programming. The user can check that the specification is not meaningless as well as execute programs, if the specification makes sense.
求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信