OO My! Object Orientation in the Tcl/Tk Core Donal K. Fellows, University of Manchester and Tcl Core Team Summary I shall present a paper on our plans to add XOTcl to the Tcl/Tk core for Tcl 8.5. Details The single feature that most people currently miss most when programming with the core features of modern Tcl/Tk is an object system. This stems from a long-standing belief that Tcl should provide just the mechanism to support such a system - which it does, witness Tk, [incr Tcl], OTcl, XOTcl, STOOOP, SNIT, etc. - and allow people to use whichever suits their application best. The problem with this approach is that it leaves Tcl itself without any object system, and this means that people who do not know better claim that Tcl does not support OO programming at all. Worse, the various object systems are not particularly interoperable with each other; combining the various systems together is non-trivial, and this is work which detracts from people just getting on and producing great programs. The way to fix this problem is for the Tcl core to distribute a "best of breed" OO system along with itself, much as it is already planned to distribute the Tile styled widget extension along with Tk. This will provide an object system that everyone can count on being present (encouraging its widespread use) while not requiring all existing Tcl users to convert their code to make use of it. Having done a review of the existing OO systems, it turns out that the best is XOTcl. This is because of a number of key features: 1. Performance. XOTcl is the fastest object system for Tcl. Not only do people want their code to be fast, but we can also count on being compared against other languages for speed in this area. 2. Flexibility. XOTcl supports many dynamic programming features in a way that Tcl programmers have come to expect from the language. 3. Support for Advanced OO Concepts. XOTcl has a number of features which are very useful and not supported by many other languages, such as subclassing classes, mixins, delegation, etc. Since the adding of these features is work currently ongoing in many of these languages, it makes marketing sense for us to get right in there with our first coordinated move in this space. 4. Ability to Simulate Other OO Systems. From the perspective of the Core Team, the most important feature of XOTcl is that it is able to simulate other Tcl-based OO systems, most notably [incr Tcl]. This means that just because we have picked one solution does not mean that we have cast the others into the outer darkness. (Some technical changes will be required though to allow other OO systems to build on a common base, most notably in the processing of things like options by default.) Taken together, these are a very strong set of arguments. As part of co-distribution, the Tcl core will gain a number of small new features to better support efficient compilation of XOTcl scripts. The first key feature will be the ability of extensions to install new operations into the Tcl bytecode compiler. There will also be a new mechanism to allow extensions to register compilation routines for commands. My talk will discuss these new features in some more detail, as well as discussing the reasoning behind the choice of any OO system and behind XOTcl in particular.