首页> 外文期刊>Formal Aspects of Computing >An algebraic approach to the design of compilers for object-oriented languages
【24h】

An algebraic approach to the design of compilers for object-oriented languages

机译:一种面向对象语言的编译器设计的代数方法

获取原文
获取原文并翻译 | 示例
           

摘要

In this paper we describe an algebraic approach to construct provably correct compilers for object-oriented languages; this is illustrated for programs written in a language similar to a sequential subset of Java. It includes recursive classes, inheritance, dynamic binding, recursion, type casts and test, assignment, and class-based visibility, but a copy semantics. In our approach, we tackle the problem of compiler correctness by reducing the task of compilation to that of program refinement. Compilation is identified with the reduction of a source program to a normal form that models the execution of object code. The normal form is generated by a series of correctness-preserving transformations that are proved sound from the basic laws of the language; therefore it is correct by construction. The main advantages of our approach are the characterisation of compilation within a uniform framework, where comparisons and translations between semantics are avoided, and the modularity and extensibility of the resulting compiler.
机译:在本文中,我们描述了一种代数方法,可为面向对象的语言构造可证明的正确编译器。对于以类似于Java的顺序子集的语言编写的程序,将对此进行说明。它包括递归类,继承,动态绑定,递归,类型转换和测试,赋值以及基于类的可见性,但包含复制语义。在我们的方法中,我们通过将编译任务简化为程序优化来解决编译器正确性的问题。通过将源程序简化为对目标代码的执行进行建模的正常形式,可以识别编译。正常形式是通过一系列保留正确性的转换生成的,这些转换已从语言的基本定律证明是正确的;因此,从结构上讲是正确的。我们的方法的主要优点是在统一框架内对编译进行表征,避免了语义之间的比较和翻译,以及所得编译器的模块化和可扩展性。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号