LOOJ: Weaving LOOM into Java

LOOJ: Weaving LOOM into Java
复制标题

LOOJ:将 LOOM 融入 Java

DOI:
10.1007/978-3-540-24851-4_18
复制
发表时间:
2004
期刊:
--
影响因子:
--
通讯作者:
Nate Foster
Nate Foster
中科院分区:
--
文献类型:
--
作者:
Kim B. Bruce;Nate Foster

文献摘要

被引文献

相似文献

LOOJ是对Java的扩展,通过添加有界参数多态性和新的类型表达式ThisClass和ThisType获得,它们与LOOM中的toMyTypein类似。通过示例,我们演示了这种语言的实用性,甚至在非常富有表现力的扩展(如GJ)上也是如此。LOOJ编译器生成标准的JVML代码,并支持所有类型的instanceof和强制类型转换,包括类型变量和其他新类型表达式。LOOJ类型系统的核心是可靠的,正如Featherweight GJ扩展的可靠性证明所证明的那样。本文还强调了在Java中同时使用类和接口作为类型所产生的困难。
LOOJ is an extension of Java obtained by adding bounded parametric polymorphism and new type expressions ThisClass and ThisType, which are similar toMyTypein LOOM. Through examples we demonstrate the utility of this language even over very expressive extensions such as GJ. The LOOJ compiler generates standard JVML code and supports instanceof and casts for all types including type variables and the other new type expressions. The core of the LOOJ type system is sound, as demonstrated by a soundness proof for an extension of Featherweight GJ. This paper also highlights difficulties that arise from the use of both classes and interfaces as types in Java.