User guide
[cl-graph.git] / website / source / user-guide-details / motivation.mmd
1 A significant portion of almost any non-trivial programming
2 effort goes into the manipulation of structured data. Many
3 data structures can be viewed as containers. These may be
4 ordered or unordered, associative (indexed) or sequential and
5 so forth. The power and beauty of some programming languages
6 derives in no small part from their ability to handle
7 container classes well (Smalltalk comes to mind) and other
8 languages have gone to great lengths to incorporate flexible
9 containers into their frameworks (C++'s STL for example).
10 Although Common Lisp includes a number of *containers*
11 (hash-tables, lists and arrays) there are many useful data
12 structures that are not built-in (e.g., binary search trees)
13 and the existing containers have a fragmented interface that
14 shows Lisp's peripatetic evolution.
15
16 The Common Lisp Container Library ({clcl}) extends Lisp in two
17 ways: it adds new container functionality and, by
18 standardizing container interfaces, it makes using them
19 significantly easier. The standard interface also lends
20 itself to more a flexible design and development process
21 since data structure decisions are easier to change as the
22 program evolves. {clcl}~ thereby expends the power of Lisp and
23 makes it an even better tool for both rapid prototyping
24 \emph{and} production code.
25
26 The remainder of this document will cover the container types
27 available in {clcl}, the methods applicable to these
28 containers, information about the internal design of {clcl}
29 and examples of containers in use. As will become evident,
30 {clcl}'s design borrows from the Standard Template Library,
31 Smalltalk and existing Lisp idioms wherever possible.