Replace $letrec with $rec
[bpt/guile.git] / doc / ref / history.texi
1 @c -*-texinfo-*-
2 @c This is part of the GNU Guile Reference Manual.
3 @c Copyright (C) 2008, 2010, 2011, 2013
4 @c Free Software Foundation, Inc.
5 @c See the file guile.texi for copying conditions.
6
7 @node History
8 @section A Brief History of Guile
9
10 Guile is an artifact of historical processes, both as code and as a
11 community of hackers. It is sometimes useful to know this history when
12 hacking the source code, to know about past decisions and future
13 directions.
14
15 Of course, the real history of Guile is written by the hackers hacking
16 and not the writers writing, so we round up the section with a note on
17 current status and future directions.
18
19 @menu
20 * The Emacs Thesis::
21 * Early Days::
22 * A Scheme of Many Maintainers::
23 * A Timeline of Selected Guile Releases::
24 * Status::
25 @end menu
26
27 @node The Emacs Thesis
28 @subsection The Emacs Thesis
29
30 The story of Guile is the story of bringing the development experience
31 of Emacs to the mass of programs on a GNU system.
32
33 Emacs, when it was first created in its GNU form in 1984, was a new
34 take on the problem of ``how to make a program''. The Emacs thesis is
35 that it is delightful to create composite programs based on an
36 orthogonal kernel written in a low-level language together with a
37 powerful, high-level extension language.
38
39 Extension languages foster extensible programs, programs which adapt
40 readily to different users and to changing times. Proof of this can be
41 seen in Emacs' current and continued existence, spanning more than a
42 quarter-century.
43
44 Besides providing for modification of a program by others, extension
45 languages are good for @emph{intension} as well. Programs built in
46 ``the Emacs way'' are pleasurable and easy for their authors to flesh
47 out with the features that they need.
48
49 After the Emacs experience was appreciated more widely, a number of
50 hackers started to consider how to spread this experience to the rest
51 of the GNU system. It was clear that the easiest way to Emacsify a
52 program would be to embed a shared language implementation into it.
53
54 @node Early Days
55 @subsection Early Days
56
57 Tom Lord was the first to fully concentrate his efforts on an
58 embeddable language runtime, which he named ``GEL'', the GNU Extension
59 Language.
60
61 GEL was the product of converting SCM, Aubrey Jaffer's implementation
62 of Scheme, into something more appropriate to embedding as a library.
63 (SCM was itself based on an implementation by George Carrette, SIOD.)
64
65 Lord managed to convince Richard Stallman to dub GEL the official
66 extension language for the GNU project. It was a natural fit, given
67 that Scheme was a cleaner, more modern Lisp than Emacs Lisp. Part of
68 the argument was that eventually when GEL became more capable, it
69 could gain the ability to execute other languages, especially Emacs
70 Lisp.
71
72 Due to a naming conflict with another programming language, Jim Blandy
73 suggested a new name for GEL: ``Guile''. Besides being a recursive
74 acronym, ``Guile'' craftily follows the naming of its ancestors,
75 ``Planner'', ``Conniver'', and ``Schemer''. (The latter was truncated
76 to ``Scheme'' due to a 6-character file name limit on an old operating
77 system.) Finally, ``Guile'' suggests ``guy-ell'', or ``Guy L.
78 Steele'', who, together with Gerald Sussman, originally discovered
79 Scheme.
80
81 Around the same time that Guile (then GEL) was readying itself for
82 public release, another extension language was gaining in popularity,
83 Tcl. Many developers found advantages in Tcl because of its shell-like
84 syntax and its well-developed graphical widgets library, Tk. Also, at
85 the time there was a large marketing push promoting Tcl as a
86 ``universal extension language''.
87
88 Richard Stallman, as the primary author of GNU Emacs, had a particular
89 vision of what extension languages should be, and Tcl did not seem to
90 him to be as capable as Emacs Lisp. He posted a criticism to the
91 comp.lang.tcl newsgroup, sparking one of the internet's legendary
92 flamewars. As part of these discussions, retrospectively dubbed the
93 ``Tcl Wars'', he announced the Free Software Foundation's intent to
94 promote Guile as the extension language for the GNU project.
95
96 It is a common misconception that Guile was created as a reaction to
97 Tcl. While it is true that the public announcement of Guile happened
98 at the same time as the ``Tcl wars'', Guile was created out of a
99 condition that existed outside the polemic. Indeed, the need for a
100 powerful language to bridge the gap between extension of existing
101 applications and a more fully dynamic programming environment is still
102 with us today.
103
104 @node A Scheme of Many Maintainers
105 @subsection A Scheme of Many Maintainers
106
107 Surveying the field, it seems that Scheme implementations correspond
108 with their maintainers on an N-to-1 relationship. That is to say, that
109 those people that implement Schemes might do so on a number of
110 occasions, but that the lifetime of a given Scheme is tied to the
111 maintainership of one individual.
112
113 Guile is atypical in this regard.
114
115 Tom Lord maintained Guile for its first year and a half or so,
116 corresponding to the end of 1994 through the middle of 1996. The
117 releases made in this time constitute an arc from SCM as a standalone
118 program to Guile as a reusable, embeddable library, but passing
119 through a explosion of features: embedded Tcl and Tk, a toolchain for
120 compiling and disassembling Java, addition of a C-like syntax,
121 creation of a module system, and a start at a rich POSIX interface.
122
123 Only some of those features remain in Guile. There were ongoing
124 tensions between providing a small, embeddable language, and one which
125 had all of the features (e.g.@: a graphical toolkit) that a modern Emacs
126 might need. In the end, as Guile gained in uptake, the development
127 team decided to focus on depth, documentation and orthogonality rather
128 than on breadth. This has been the focus of Guile ever since, although
129 there is a wide range of third-party libraries for Guile.
130
131 Jim Blandy presided over that period of stabilization, in the three
132 years until the end of 1999, when he too moved on to other projects.
133 Since then, Guile has had a group maintainership. The first group was
134 Maciej Stachowiak, Mikael Djurfeldt, and Marius Vollmer, with Vollmer
135 staying on the longest. By late 2007, Vollmer had mostly moved on to
136 other things, so Neil Jerram and Ludovic Court@`es
137 stepped up to take on the primary maintenance responsibility. Jerram and
138 Court@`es were joined by Andy Wingo in late 2009.
139
140 Of course, a large part of the actual work on Guile has come from
141 other contributors too numerous to mention, but without whom the world
142 would be a poorer place.
143
144 @node A Timeline of Selected Guile Releases
145 @subsection A Timeline of Selected Guile Releases
146
147 @table @asis
148 @item guile-i --- 4 February 1995
149 SCM, turned into a library.
150
151 @item guile-ii --- 6 April 1995
152 A low-level module system was added. Tcl/Tk support was added,
153 allowing extension of Scheme by Tcl or vice versa. POSIX support was
154 improved, and there was an experimental stab at Java integration.
155
156 @item guile-iii --- 18 August 1995
157 The C-like syntax, ctax, was improved, but mostly this release
158 featured a start at the task of breaking Guile into pieces.
159
160 @item 1.0 --- 5 January 1997
161 @code{#f} was distinguished from @code{'()}. User-level, cooperative
162 multi-threading was added. Source-level debugging became more useful,
163 and programmer's and user's manuals were begun. The module system
164 gained a high-level interface, which is still used today in more or
165 less the same form.
166
167 @item 1.1 --- 16 May 1997
168 @itemx 1.2 --- 24 June 1997
169 Support for Tcl/Tk and ctax were split off as separate packages, and
170 have remained there since. Guile became more compatible with SCSH, and
171 more useful as a UNIX scripting language. Libguile could now be built as
172 a shared library, and third-party extensions written in C became
173 loadable via dynamic linking.
174
175 @item 1.3.0 --- 19 October 1998
176 Command-line editing became much more pleasant through the use of the
177 readline library. The initial support for internationalization via
178 multi-byte strings was removed; 10 years were to pass before proper
179 internationalization would land again. Initial Emacs Lisp support
180 landed, ports gained better support for file descriptors, and fluids
181 were added.
182
183 @item 1.3.2 --- 20 August 1999
184 @itemx 1.3.4 --- 25 September 1999
185 @itemx 1.4 --- 21 June 2000
186 A long list of lispy features were added: hooks, Common Lisp's
187 @code{format}, optional and keyword procedure arguments,
188 @code{getopt-long}, sorting, random numbers, and many other fixes and
189 enhancements. Guile also gained an interactive debugger, interactive
190 help, and better backtraces.
191
192 @item 1.6 --- 6 September 2002
193 Guile gained support for the R5RS standard, and added a number of SRFI
194 modules. The module system was expanded with programmatic support for
195 identifier selection and renaming. The GOOPS object system was merged
196 into Guile core.
197
198 @item 1.8 --- 20 February 2006
199 Guile's arbitrary-precision arithmetic switched to use the GMP
200 library, and added support for exact rationals. Guile's embedded
201 user-space threading was removed in favor of POSIX pre-emptive
202 threads, providing true multiprocessing. Gettext support was added,
203 and Guile's C API was cleaned up and orthogonalized in a massive way.
204
205 @item 2.0 --- 16 February 2010
206 A virtual machine was added to Guile, along with the associated compiler
207 and toolchain. Support for internationalization was finally
208 reimplemented, in terms of unicode, locales, and libunistring. Running
209 Guile instances became controllable and debuggable from within Emacs,
210 via Geiser. Guile caught up to features found in a number of other
211 Schemes: SRFI-18 threads, module-hygienic macros, a profiler, tracer,
212 and debugger, SSAX XML integration, bytevectors, a dynamic FFI,
213 delimited continuations, module versions, and partial support for R6RS.
214
215 @item 2.2 --- mid-2014
216 The virtual machine and introduced in 2.0 was completely rewritten,
217 along with much of the compiler and toolchain. This speeds up many
218 Guile programs as well as reducing startup time and memory usage. A PEG
219 parser toolkit was added, making it easier to write other language
220 frontends.
221 @end table
222
223 @node Status
224 @subsection Status, or: Your Help Needed
225
226 Guile has achieved much of what it set out to achieve, but there is
227 much remaining to do.
228
229 There is still the old problem of bringing existing applications into
230 a more Emacs-like experience. Guile has had some successes in this
231 respect, but still most applications in the GNU system are without
232 Guile integration.
233
234 Getting Guile to those applications takes an investment, the
235 ``hacktivation energy'' needed to wire Guile into a program that only
236 pays off once it is good enough to enable new kinds of behavior. This
237 would be a great way for new hackers to contribute: take an
238 application that you use and that you know well, think of something
239 that it can't yet do, and figure out a way to integrate Guile and
240 implement that task in Guile.
241
242 With time, perhaps this exposure can reverse itself, whereby programs
243 can run under Guile instead of vice versa, eventually resulting in the
244 Emacsification of the entire GNU system. Indeed, this is the reason
245 for the naming of the many Guile modules that live in the @code{ice-9}
246 namespace, a nod to the fictional substance in Kurt Vonnegut's
247 novel, Cat's Cradle, capable of acting as a seed crystal to
248 crystallize the mass of software.
249
250 Implicit to this whole discussion is the idea that dynamic languages
251 are somehow better than languages like C. While languages like C have
252 their place, Guile's take on this question is that yes, Scheme is more
253 expressive than C, and more fun to write. This realization carries an
254 imperative with it to write as much code in Scheme as possible rather
255 than in other languages.
256
257 These days it is possible to write extensible applications almost
258 entirely from high-level languages, through byte-code and native
259 compilation, speed gains in the underlying hardware, and foreign call
260 interfaces in the high-level language. Smalltalk systems are like this,
261 as are Common Lisp-based systems. While there already are a number of
262 pure-Guile applications out there, users still need to drop down to C
263 for some tasks: interfacing to system libraries that don't have prebuilt
264 Guile interfaces, and for some tasks requiring high performance. Native
265 ahead-of-time compilation, planned for Guile 3.0, should help with
266 this.
267
268 Still, even with an all-Guile application, sometimes you want to
269 provide an opportunity for users to extend your program from a
270 language with a syntax that is closer to C, or to Python. Another
271 interesting idea to consider is compiling e.g.@: Python to Guile. It's
272 not that far-fetched of an idea: see for example IronPython or JRuby.
273
274 And then there's Emacs itself. Guile's Emacs Lisp support has reached
275 an excellent level of correctness, robustness, and speed. However there
276 is still work to do to finish its integration into Emacs itself. This
277 will give lots of exciting things to Emacs: native threads, a real
278 object system, more sophisticated types, cleaner syntax, and access to
279 all of the Guile extensions.
280
281 Finally, there is another axis of crystallization, the axis between
282 different Scheme implementations. Guile does not yet support the latest
283 Scheme standard, R7RS, and should do so. Like all standards, R7RS is
284 imperfect, but supporting it will allow more code to run on Guile
285 without modification, and will allow Guile hackers to produce code
286 compatible with other schemes. Help in this regard would be much
287 appreciated.