scispace - formally typeset
Search or ask a question
Book

The Art of the Metaobject Protocol

TL;DR: In this article, the authors present a new approach to programming language design, which resolves fundamental tensions between elegance and efficiency, called metaobject protocols, which are interfaces to the lanaguage that give users the ability to incrementally modify the language's behavior and implementation, as well as to write programs within the language.
Abstract: From the Publisher: This book presents a new approach to programming language design, which resolves fundamental tensions between elegance and efficiency. Metaobject protocols are interfaces to the lanaguage that gives users the ability to incrementally modify the language's behavior and implementation, as well as the ability to write programs within the language. In this way, a metaobject protocol allows users to adjust the lanaguage to better suit their needs.
Citations
More filters
Journal ArticleDOI
TL;DR: In this article, the authors identify patterns in the decision, analysis, design, and implementation phases of DSL development and discuss domain analysis tools and language development systems that may help to speed up DSL development.
Abstract: Domain-specific languages (DSLs) are languages tailored to a specific application domain. They offer substantial gains in expressiveness and ease of use compared with general-purpose programming languages in their domain of application. DSL development is hard, requiring both domain knowledge and language development expertise. Few people have both. Not surprisingly, the decision to develop a DSL is often postponed indefinitely, if considered at all, and most DSLs never get beyond the application library stage.Although many articles have been written on the development of particular DSLs, there is very limited literature on DSL development methodologies and many questions remain regarding when and how to develop a DSL. To aid the DSL developer, we identify patterns in the decision, analysis, design, and implementation phases of DSL development. Our patterns improve and extend earlier work on DSL design patterns. We also discuss domain analysis tools and language development systems that may help to speed up DSL development. Finally, we present a number of open problems.

1,778 citations

Book ChapterDOI
02 Oct 2000
TL;DR: This work describes ProtEgE-2000 knowledge model that makes the import and export of knowledge bases from and to other knowledge-base servers easy and demonstrates that it can resolve many of the differences between the knowledge models of ProtEe-2000 and Resource Description Framework (RDF)--a system for annotating Web pages with knowledge elements--by defining a new metaclass set.
Abstract: Knowledge-based systems have become ubiquitous in recent years. Knowledge-base developers need to be able to share and reuse knowledge bases that they build. Therefore, interoperability among different knowledge-representation systems is essential. The Open Knowledge-Base Connectivity protocol (OKBC) is a common query and construction interface for frame-based systems that facilitates this interoperability. ProtEgE-2000 is an OKBC-compatible knowledge-base-editing environment developed in our laboratory. We describe ProtEgE-2000 knowledge model that makes the import and export of knowledge bases from and to other knowledge-base servers easy. We discuss how the requirements of being a usable and configurable knowledge-acquisition tool affected our decisions in the knowledge-model design. ProtEgE-2000 also has a flexible metaclass architecture which provides configurable templates for new classes in the knowledge base. The use of metaclasses makes ProtEgE-2000 easily extensible and enables its use with other knowledge models. We demonstrate that we can resolve many of the differences between the knowledge models of ProtEgE-2000 and Resource Description Framework (RDF)--a system for annotating Web pages with knowledge elements--by defining a new metaclass set. Resolving the differences between the knowledge models in declarative way enables easy adaptation of ProtEgE-2000 as an editor for other knowledge-representation systems.

754 citations

01 Jan 2000
TL;DR: This paper proposes that the distinguishing characteristic of Aspect-Oriented Programming (AOP) systems is that they allow programming by making quantified programmatic assertions over programs written by programmers oblivious to such assertions.
Abstract: This paper proposes that the distinguishing characteristic of Aspect-Oriented Programming (AOP) systems is that they allow programming by making quantified programmatic assertions over programs written by programmers oblivious to such assertions. Thus, AOP systems can be analyzed with respect to three critical dimensions: the kinds of quantifications allowed, the nature of the actions that can be asserted, and the mechanism for combining base-level actions with asserted actions. Consequences of this perspective are the recognition that certain systems are not AOP and that some mechanisms are expressive enough to allow programming an AOP system within them. A corollary is that while AOP can be applied to Object-Oriented Programming, it is an independent concept applicable to other programming styles.

643 citations

Journal ArticleDOI
TL;DR: This paper presents a method to reduce the execution cost of mutation testing for OO programs by using two key technologies, mutant schemata generation (MSG) and bytecode translation.
Abstract: Several module and class testing techniques have been applied to object-oriented (OO) programs, but researchers have only recently begun developing test criteria that evaluate the use of key OO features such as inheritance, polymorphism, and encapsulation. Mutation testing is a powerful testing technique for generating software tests and evaluating the quality of software. However, the cost of mutation testing has traditionally been so high that it cannot be applied without full automated tool support. This paper presents a method to reduce the execution cost of mutation testing for OO programs by using two key technologies, mutant schemata generation (MSG) and bytecode translation. This method adapts the existing MSG method for mutants that change the program behaviour and uses bytecode translation for mutants that change the program structure. A key advantage is in performance: only two compilations are required and both the compilation and execution time for each is greatly reduced. A mutation tool based on the MSG/bytecode translation method has been built and used to measure the speedup over the separate compilation approach. Experimental results show that the MSG/bytecode translation method is about five times faster than separate compilation. Copyright © 2004 John Wiley & Sons, Ltd.

642 citations

Proceedings ArticleDOI
22 Oct 2000
TL;DR: This paper shows how system implementors can use meta-level compilation (MC) to write simple, system-specific compiler extensions that automatically check their code for rule violations and demonstrates the effectiveness of the MC approach by applying it to four complex, real systems.
Abstract: Systems software such as OS kernels, embedded systems, and libraries must obey many rules for both correctness and performance. Common examples include "accesses to variable A must be guarded by lock B," "system calls must check user pointers for validity before using them," and "message handlers should free their buffers as quickly as possible to allow greater parallelism." Unfortunately, adherence to these rules is largely unchecked.This paper attacks this problem by showing how system implementors can use meta-level compilation (MC) to write simple, system-specific compiler extensions that automatically check their code for rule violations. By melding domain-specific knowledge with the automatic machinery of compilers, MC brings the benefits of language-level checking and optimizing to the higher, "meta" level of the systems implemented in these languages. This paper demonstrates the effectiveness of the MC approach by applying it to four complex, real systems: Linux, OpenBSD, the Xok exokernel, and the FLASH machine's embedded software. MC extensions found roughly 500 errors in these systems and led to numerous kernel patches. Most extensions were less than a hundred lines of code and written by implementors who had a limited understanding of the systems checked.

599 citations