Commit | Line | Data |
---|---|---|
6a2b0a5e MD |
1 | This file states the goals of Guile. |
2 | ||
3 | * Goals of Guile | |
4 | ||
5 | Guile is many things to many people. It has multiple ways to approach | |
6 | it: as a C library that provides an extension language, as a | |
7 | programming language in its own right, as a interface to the operating | |
8 | system, as an interactive shell, or as a platform that integrates many | |
9 | independent subsystems. | |
10 | ||
11 | These different roles have a lot in common, but there are also some | |
12 | opposing forces that need to be balanced. | |
13 | ||
14 | Not everything of what is outlined below has been realized yet. The | |
15 | things that are missing will receive high priority from the | |
16 | maintainers of Guile. One thing that is not mentioned below because | |
17 | it goes without saying is documentation. It is of course a goal of | |
18 | Guile to have high quality documentation. | |
19 | ||
20 | More information about the current status of Guile and planned changed | |
21 | can be found in the file "plans.text". | |
22 | ||
23 | ** Guile as an extension language library | |
24 | ||
25 | Guile's primary aim is to provide a good extension language which is | |
163fada3 | 26 | easy to add to an application written in C for the GNU system. This |
6a2b0a5e MD |
27 | means that it must export the features of a higher level language in a |
28 | way that makes it easy not to break them from C code. | |
29 | ||
30 | For example, one important feature of Guile is automatic garbage | |
31 | collection. The C interface to the garbage collector makes it easy to | |
32 | use its services for the data structures of the application itself. | |
33 | ||
34 | ** Guile as a programming language | |
35 | ||
36 | It is an aim to support easy programming using Guile. This includes | |
37 | providing the powerful features of the programming language Scheme, | |
38 | like garbage collection, dynamic types, hygienic macros and higher | |
39 | order functions. | |
40 | ||
41 | This also includes things that go beyond standard Scheme, like a | |
42 | module system to manage multiple name spaces, a system for object | |
43 | oriented programming, support for comfortable multi-threading, and | |
44 | internationalization features like Unicode support. | |
45 | ||
46 | To make it useful, Guile offers good performance. | |
47 | ||
48 | ** Guile as an interface to the operating system | |
49 | ||
50 | Guile supports most of the POSIX system calls. Most of Scsh is | |
51 | available to Guile users and Guile programs. Beyond POSIX, Guile also | |
52 | makes available important system libraries like the graphical toolkit | |
53 | Gtk+. | |
54 | ||
55 | ** Guile as an interactive shell | |
56 | ||
57 | Guile provides a command line interface with readline support. The | |
58 | interactive features of the programming language allow you to | |
59 | incrementally alter a running system. A integrated debugger allows | |
60 | you to analyze such a running system in great detail. | |
61 | ||
62 | Guile provides online documentation for most of its features. | |
63 | ||
64 | Guile can also be controlled from Emacs. This allows you to update | |
65 | the definition of a function or some other object in a Guile process | |
66 | with the touch of a few keys. You have access to the documentation in | |
67 | a context sensitive way. It also integrates the debugger nicely into | |
68 | your editing environment. | |
69 | ||
70 | ** Guile as an integration platform | |
71 | ||
72 | With all the features describes above, Guile allows the implementation | |
73 | of well behaved modules. When most of an application is implemented | |
74 | as modules with generality and re-usability in mind, Guile will be the | |
75 | platform where the integration and reusing will take place. | |
76 | ||
77 | Thus, Guile makes it easy to factor your application into well | |
78 | separated modules and then finish it off by combining them with a thin | |
79 | layer of Scheme code. | |
80 | ||
81 | Guile has support for writing modules in C or other compiled | |
82 | languages. | |
163fada3 MD |
83 | |
84 | ** Guile as a basis for other languages | |
85 | ||
86 | Scheme is a very powerful language, which makes it possible | |
87 | to implement other languages by translating them into Scheme. | |
88 | ||
89 | By writing translators that convert various popular scripting | |
90 | languages into Scheme, we can enable users to choose their favorite | |
91 | languages for extending any program that provides extensibility using | |
92 | Guile. |