Smalltalk-80: the language and its implementation
Smalltalk-80: the language and its implementation
A overview of modular smalltalk
OOPSLA '88 Conference proceedings on Object-oriented programming systems, languages and applications
How to make ad-hoc polymorphism less ad hoc
POPL '89 Proceedings of the 16th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
OOPSLA/ECOOP '90 Proceedings of the European conference on object-oriented programming on Object-oriented programming systems, languages, and applications
ECOOP '01 Proceedings of the 15th European Conference on Object-Oriented Programming
Relaxed MultiJava: balancing extensibility and modular typechecking
OOPSLA '03 Proceedings of the 18th annual ACM SIGPLAN conference on Object-oriented programing, systems, languages, and applications
Classbox/J: controlling the scope of change in Java
OOPSLA '05 Proceedings of the 20th annual ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications
Adding open modules to AspectJ
Proceedings of the 5th international conference on Aspect-oriented software development
Classboxes: controlling visibility of class extensions
Computer Languages, Systems and Structures
Mostly modular compilation of crosscutting concerns by contextual predicate dispatch
Proceedings of the ACM international conference on Object oriented programming systems languages and applications
Open modules: modular reasoning about advice
ECOOP'05 Proceedings of the 19th European conference on Object-Oriented Programming
Hi-index | 0.00 |
A class extension, also known as open classes, allows programmers to modify existing classes and thus it is supported by several programming languages. However, class extensions imply a risk that they supply different definitions for the same method and those definitions conflict with each other. Several module systems have been proposed to address these conflicts. One approach lexically restricts the scope of class extensions but they do not allow us to change the behavior of methods called indirectly. Another approach is to make only class extensions explicitly imported effective while preserving the local rebinding property, which allows us to change the behavior of indirectly called methods. However, this approach causes conflicts if potentially conflicting class extensions are imported together. To address this problem, we propose a new module system named method shelters. A method shelter confines a scope of class extensions while preserving the local rebinding property. Hidden class extensions in a method shelter are not visible from the outside. We implemented a prototype of the proposed module system in Ruby. This paper illustrates several examples of the use of method shelters and also shows the results of benchmarks on our prototype.