首页> 外国专利> Typed intermediate representation for object-oriented languages

Typed intermediate representation for object-oriented languages

机译:面向对象语言的类型化中间表示

摘要

Described herein are typed intermediate representations of object-oriented source code that preserve notions of class names, as well as add structure-based information related to classes in the source code. Types in the intermediate representation are divided into corresponding class name-based types and associated structure-based record types. The structure-based record type comprises a layout of objects that are instances of the corresponding class name-based types, where the object comprises one or more data fields and one or more virtual method members. Dynamic types can be abstracted in the form of existential types with sub-classing bounded quantifications. This makes type checking decidable. Existential types bind type variables with sub-classing bounds to represent dynamic types of objects. The layout of those objects can be approximated by structure-based record types. The types of virtual methods in the approximation record types include type variables that represent the dynamic types of those objects to guarantee safety.
机译:在此描述的是面向对象的源代码的类型化中间表示,这些中间表示保留了类名的概念,并在源代码中添加了与类有关的基于结构的信息。中间表示形式中的类型分为相应的基于类名称的类型和关联的基于结构的记录类型。基于结构的记录类型包括对象的布局,这些对象是相应的基于类名称的类型的实例,其中该对象包括一个或多个数据字段和一个或多个虚拟方法成员。动态类型可以以存在类型的形式抽象化,并带有子类化的有限量化。这样就可以确定类型检查。现有类型将类型变量与子类范围绑定在一起,以表示对象的动态类型。这些对象的布局可以通过基于结构的记录类型来近似。逼近记录类型中的虚拟方法的类型包括代表那些对象的动态类型的类型变量,以确保安全性。

著录项

相似文献

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

客服邮箱:kefu@zhangqiaokeyan.com

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

  • 服务号