CommonLoops: The Evolution of Object-Oriented Programming in Lisp
CommonLoops, an early extension of Common Lisp, stands as a significant milestone in the development of object-oriented programming (OOP) languages. Introduced in 1986 by Hewlett-Packard (HP), CommonLoops represented a fusion of two powerful concepts: Common Lisp, a dynamic and versatile functional programming language, and object-oriented programming (OOP), a paradigm that promotes modularity and reusability through objects and their interactions. This article delves into the origins, features, historical context, and lasting impact of CommonLoops on the development of object-oriented programming, particularly its role in the evolution of the Common Lisp Object System (CLOS).
Origins of CommonLoops
To fully appreciate CommonLoops, it is essential to understand the programming landscape in which it emerged. During the 1980s, the computing world was witnessing a shift from procedural programming to object-oriented programming. While languages like C++ and Smalltalk were pushing OOP into the mainstream, Common Lisp—already established as a powerful and flexible functional programming language—was not inherently designed to support OOP. This gap in the language’s capabilities became apparent as developers began to see the potential of OOP concepts like inheritance, polymorphism, and encapsulation.

Hewlett-Packard’s development of CommonLoops sought to fill this gap by adding object-oriented features to the existing Common Lisp framework. The name “CommonLoops” itself is a nod to the earlier object-oriented system “Loops” used in Interlisp-D, a Lisp dialect developed at Xerox PARC. Both CommonLoops and Loops sought to extend Lisp with object-oriented programming features, but CommonLoops was designed to be more portable and compatible with various implementations of Common Lisp.
Features of CommonLoops
CommonLoops incorporated several advanced OOP features that would later become essential in modern object-oriented languages. Some of the key features of CommonLoops include:
-
Multiple Inheritance: CommonLoops allowed objects to inherit behaviors and properties from more than one parent class. This feature enabled more complex and flexible object models, allowing for a greater degree of code reuse and adaptability.
-
Generic Functions: A distinctive feature of CommonLoops, and one that would be further refined in later systems, was the support for generic functions. Unlike traditional methods that are defined within specific classes, generic functions are independent of any particular class and can operate on objects of different types. This approach is fundamental to the concept of polymorphism in OOP.
-
Method Combination: CommonLoops allowed multiple methods to combine in various ways, depending on the types of the arguments passed to them. This feature gave developers fine-grained control over the behavior of objects and methods, enabling more flexible and efficient program design.
-
Multi-methods: Multi-methods in CommonLoops allowed methods to be defined based on the types of multiple arguments, rather than just a single object. This feature made it easier to handle complex interactions between objects of different types.
-
Metaobjects: One of the most powerful and innovative aspects of CommonLoops was its use of metaobjects. Metaobjects are objects that define the behavior of other objects, allowing for the dynamic customization and modification of classes and instances. This feature paved the way for later meta-programming techniques, which have become an integral part of many modern programming languages.
-
Portable CommonLoops (PCL): In an effort to make CommonLoops widely accessible, HP developed a portable implementation of the system called Portable CommonLoops (PCL). PCL was designed to run on all major Common Lisp implementations of the time, making it possible for developers to take advantage of the new object-oriented features without being tied to a specific Lisp dialect or platform.
The Influence on CLOS
CommonLoops played a pivotal role in the development of the Common Lisp Object System (CLOS), which eventually became the official object-oriented system for Common Lisp. In fact, CommonLoops and another system called New Flavors (developed by Symbolics) were the two primary precursors to CLOS. Both systems introduced key OOP concepts, but it was CLOS that would eventually be standardized by the American National Standards Institute (ANSI) in 1994, solidifying its place in the Common Lisp specification.
One of the defining features of CLOS was its support for both single and multiple inheritance, a concept borrowed directly from CommonLoops. Furthermore, CLOS inherited the idea of generic functions, method combination, and multi-methods, all of which were pioneered by CommonLoops. The development of CLOS marked a significant step forward in the integration of object-oriented programming into the Lisp family of languages, and much of its design and philosophy can be traced back to the innovations introduced by CommonLoops.
Legacy and Impact
While CommonLoops itself did not achieve the same level of widespread adoption as languages like C++ or Java, its influence on the programming world cannot be overstated. The features it introduced—particularly generic functions, multiple inheritance, and metaobjects—have become fundamental to many modern object-oriented programming languages. Moreover, the lessons learned from the development of CommonLoops contributed to the eventual success of CLOS, which remains a powerful and flexible object-oriented system within the Lisp ecosystem.
The importance of CommonLoops lies not only in its technical innovations but also in the way it bridged the gap between functional and object-oriented programming. By incorporating object-oriented features into the Common Lisp environment, CommonLoops demonstrated that OOP and functional programming could coexist and complement each other, paving the way for the hybrid programming paradigms that are common today.
Conclusion
CommonLoops stands as a testament to the ingenuity and vision of its creators at Hewlett-Packard. Its introduction of object-oriented features into Common Lisp was a pioneering effort that laid the groundwork for the modern object-oriented systems we use today. The legacy of CommonLoops can be seen in the development of CLOS, the continued evolution of Lisp-based object-oriented systems, and the widespread adoption of OOP principles in languages such as Python, Ruby, and Java.
In many ways, CommonLoops is a forgotten gem of computer science history—an early attempt to merge the best of functional and object-oriented programming into a cohesive, dynamic system. Though it may not have achieved mainstream success, its influence continues to resonate in the design of modern programming languages, and its contributions to the field of computer science remain significant to this day.