Next: , Up: Top  


Introduction

GNU Smalltalk is an implementation that closely follows the Smalltalk-80 language as described in the book Smalltalk-80: the Language and its Implementation by Adele Goldberg and David Robson, which will hereinafter be referred to as the Blue Book.

The Smalltalk programming language is an object oriented programming language. This means, for one thing, that when programming you are thinking of not only the data that an object contains, but also of the operations available on that object. The object’s data representation capabilities and the operations available on the object are “inseparable”; the set of things that you can do with an object is defined precisely by the set of operations, which Smalltalk calls methods, that are available for that object: each object belongs to a class (a datatype and the set of functions that operate on it) or, better, it is an instance of that class. You cannot even examine the contents of an object from the outside—to an outsider, the object is a black box that has some state and some operations available, but that’s all you know: when you want to perform an operation on an object, you can only send it a message, and the object picks up the method that corresponds to that message.

In the Smalltalk language, everything is an object. This includes not only numbers and all data structures, but even classes, methods, pieces of code within a method (blocks or closures), stack frames (contexts), etc. Even if and while structures are implemented as methods sent to particular objects.

Unlike other Smalltalks (including Smalltalk-80), GNU Smalltalk emphasizes Smalltalk’s rapid prototyping features rather than the graphical and easy-to-use nature of the programming environment (did you know that the first GUIs ever ran under Smalltalk?). The availability of a large body of system classes, once you master them, makes it pretty easy to write complex programs which are usually a task for the so called scripting languages. Therefore, even though we have a GUI environment based on GTK (see GTK and VisualGST), the goal of the GNU Smalltalk project is currently to produce a complete system to be used to write your scripts in a clear, aesthetically pleasing, and philosophically appealing programming language.

An example of what can be obtained with Smalltalk in this novel way can be found in Class reference in the GNU Smalltalk Library Reference. That part of the manual is entirely generated by a Smalltalk program, starting from the source code for the class libraries distributed together with the system.


Next: , Up: Top