*** empty log message ***
[bpt/guile.git] / NEWS
1 Guile NEWS --- history of user-visible changes. 2 Aug 1996 -*- text -*-
2 Copyright (C) 1996 Free Software Foundation, Inc.
3 See the end for copying conditions.
4
5 Please send Guile bug reports to bug-guile@prep.ai.mit.edu.
6 \f
7 Guile 1.0b3
8
9 Changes since Thursday, September 5:
10
11
12 * Guile now distinguishes between #f and the empty list.
13
14 This is for compatibility with the IEEE standard, the (possibly)
15 upcoming Revised^5 Report on Scheme, and many extant Scheme
16 implementations.
17
18 Guile used to have #f and '() denote the same object, to make Scheme's
19 type system more compatible with Emacs Lisp's. However, the change
20 caused too much trouble for Scheme programmers, and we found another
21 way to reconcile Emacs Lisp with Scheme that didn't require this.
22
23
24 * You can now use Guile as a shell script interpreter.
25
26 To paraphrase the SCSH manual:
27
28 When Unix tries to execute an executable file whose first two
29 characters are the `#!', it treats the file not as machine code to
30 be directly executed by the native processor, but as source code
31 to be executed by some interpreter. The interpreter to use is
32 specified immediately after the #! sequence on the first line of
33 the source file. The kernel reads in the name of the interpreter,
34 and executes that instead. It passes the interpreter the source
35 filename as its first argument, with the original arguments
36 following. Consult the Unix man page for the `exec' system call
37 for more information.
38
39 Guile now recognizes a '-s' command line switch, whose argument is the
40 name of a file of Scheme code to load. It also treats the two
41 characters `#!' as the start of a comment, terminated by `!#'. Thus,
42 to make a file of Scheme code directly executable by Unix, insert the
43 following two lines at the top of the file:
44
45 #!/usr/local/bin/guile -s
46 !#
47
48 Guile treats the argument of the `-s' command-line switch as the name
49 of a file of Scheme code to load, and treats the sequence `#!' as the
50 start of a block comment, terminated by `!#'.
51
52 For example, here's a version of 'echo' written in Scheme:
53
54 #!/usr/local/bin/guile -s
55 !#
56 (let loop ((args (cdr (program-arguments))))
57 (if (pair? args)
58 (begin
59 (display (car args))
60 (if (pair? (cdr args))
61 (display " "))
62 (loop (cdr args)))))
63 (newline)
64
65 Why does `#!' start a block comment terminated by `!#', instead of the
66 end of the line? That is the notation SCSH uses, and although we
67 don't yet support the other SCSH features that motivate that choice,
68 we would like to be backward-compatible with any existing Guile
69 scripts once we do.
70
71 Note that some very old Unix systems don't support the `#!' syntax.
72
73
74 * You can now run Guile without installing it.
75
76 Previous versions of the interactive Guile interpreter (`guile')
77 couldn't start up unless Guile's Scheme library had been installed;
78 they used the value of the environment variable `SCHEME_LOAD_PATH'
79 later on in the startup process, but not to find the startup code
80 itself. Now Guile uses `SCHEME_LOAD_PATH' in all searches for Scheme
81 code.
82
83 To run Guile without installing it, build it in the normal way, and
84 then set the environment variable `SCHEME_LOAD_PATH' to a
85 colon-separated list of directories, including the top-level directory
86 of the Guile sources. For example, if you unpacked Guile so that the
87 full filename of this NEWS file is /home/jimb/guile-1.0b3/NEWS, then
88 you might say
89
90 export SCHEME_LOAD_PATH=/home/jimb/my-scheme:/home/jimb/guile-1.0b3
91
92 * Guile's header files should no longer conflict with your system's
93 header files.
94
95 In order to compile code which #included <libguile.h>, previous
96 versions of Guile required you to add a directory containing all the
97 Guile header files to your #include path. This was a problem, since
98 Guile's header files have names which conflict with many systems'
99 header files.
100
101 Now only <libguile.h> need appear in your #include path; you must
102 refer to all Guile's other header files as <libguile/mumble.h>.
103 Guile's installation procedure puts libguile.h in $(includedir), and
104 the rest in $(includedir)/libguile.
105
106 * The compiled-library-path function has been deleted from libguile.
107
108 * A variable and two new functions have been added to libguile:
109
110 ** The variable %load-path now tells Guile which directories to search
111 for Scheme code. Its value is a list of strings, each of which names
112 a directory.
113
114 ** (%search-load-path FILENAME) searches the directories listed in the
115 value of the %load-path variable for a Scheme file named FILENAME. If
116 it finds a match, then it returns its full filename. Otherwise, it
117 returns #f. %search-load-path will not return matches that refer to
118 directories.
119
120 ** (%try-load-path FILENAME :optional CASE-INSENSITIVE-P SHARP)
121 searches the directories listed in %load-path for a file named
122 FILENAME, and loads it if it finds it. If it can't read FILENAME for
123 any reason, it throws an error.
124
125 The arguments CASE-INSENSITIVE-P and SHARP are interpreted as by the
126 %try-load function.
127
128
129 \f
130 This is the beginning of recorded history.
131
132 \f
133 Copyright information:
134
135 Copyright (C) 1996 Free Software Foundation, Inc.
136
137 Permission is granted to anyone to make or distribute verbatim copies
138 of this document as received, in any medium, provided that the
139 copyright notice and this permission notice are preserved,
140 thus giving the recipient permission to redistribute in turn.
141
142 Permission is granted to distribute modified versions
143 of this document, or of portions of it,
144 under the above conditions, provided also that they
145 carry prominent notices stating who last changed them.
146