1997-10-03 Mikael Djurfeldt <mdj@nada.kth.se>
[bpt/guile.git] / NEWS
CommitLineData
f7b47737
JB
1Guile NEWS --- history of user-visible changes. -*- text -*-
2Copyright (C) 1996, 1997 Free Software Foundation, Inc.
5c54da76
JB
3See the end for copying conditions.
4
16f2ebea 5Please send Guile bug reports to bug-guile@prep.ai.mit.edu.
5c54da76 6\f
c484bf7f
JB
7Changes since Guile 1.2:
8
9* Changes to the distribution
10
3a97e020
MD
11** libguile/append.h, libguile/append.c, libguile/sequences.h,
12libguile/sequences.c removed.
13
c484bf7f
JB
14* Changes to the stand-alone interpreter
15
16* Changes to the procedure for linking libguile with your programs
17
18* Changes to Scheme functions and syntax
7ad3c1e7 19
9c3fb66f
MV
20** The detection of circular references has been extended to structs.
21That is, a structure that -- in the process of being printed -- prints
22itself does not lead to infinite recursion.
23
04c76b58
MV
24** There is now some basic support for fluids. Please read
25"libguile/fluid.h" to find out more. It is accessible from Scheme with
9c3fb66f
MV
26the following functions and macros:
27
28Function: make-fluid
29
30 Create a new fluid object. Fluids are not special variables or
31 some other extension to the semantics of Scheme, but rather
32 ordinary Scheme objects. You can store them into variables (that
33 are still lexically scoped, of course) or into any other place you
34 like. Every fluid has a initial value of `#f'.
04c76b58 35
9c3fb66f 36Function: fluid? OBJ
04c76b58 37
9c3fb66f 38 Test whether OBJ is a fluid.
04c76b58 39
9c3fb66f
MV
40Function: fluid-ref FLUID
41Function: fluid-set! FLUID VAL
04c76b58
MV
42
43 Access/modify the fluid FLUID. Modifications are only visible
44 within the current dynamic root (that includes threads).
45
9c3fb66f
MV
46Function: with-fluids* FLUIDS VALUES THUNK
47
48 FLUIDS is a list of fluids and VALUES a corresponding list of
49 values for these fluids. Before THUNK gets called the values are
50 installed in the fluids and the old values of the fluids are
51 saved in the VALUES list. When the flow of control leaves THUNK
52 or reenters it, the values get swapped again. You might think of
53 this as a `safe-fluid-excursion'. Note that the VALUES list is
54 modified by `with-fluids*'.
55
56Macro: with-fluids ((FLUID VALUE) ...) FORM ...
57
58 The same as `with-fluids*' but with a different syntax. It looks
59 just like `let', but both FLUID and VALUE are evaluated. Remember,
60 fluids are not special variables but ordinary objects. FLUID
61 should evaluate to a fluid.
04c76b58 62
3a97e020
MD
63** Removed procedures:
64
65list-length, list-append, list-append!, list-reverse, list-reverse!
66
298aa6e3
MD
67** array-map renamed to array-map!
68
69** serial-array-map renamed to serial-array-map!
70
64d01d13
GH
71* Changes to system call interfaces:
72
73** close-port, close-input-port and close-output-port now return a
74boolean instead of an `unspecified' object. #t means that the port
75was successfully closed, while #f means it was already closed. It is
76also now possible for these procedures to raise an exception if an
77error occurs (some errors from write can be delayed until close.)
78
6afcd3b2
GH
79** the first argument to chmod, fcntl, ftell and fseek can now be a
80file descriptor.
81
82** the third argument to fcntl is now optional.
83
84** the first argument to chown can now be a file descriptor or a port.
85
86** the argument to stat can now be a port.
87
64d01d13
GH
88** The following new procedures have been added (most use scsh
89interfaces):
90
91** close PORT/FD
92Similar to close-port, but also works on file descriptors. A side
93effect of closing a file descriptor is that any ports using that file
94descriptor are moved to a different file descriptor and have
95their revealed counts set to zero.
96
97The next five procedures perform a dup2 system call, if NEWFD (an
98integer) is supplied, otherwise a dup. The file descriptor to be
99duplicated can be supplied as an integer or wrapped in a port. The
100type of value returned varies depending on which procedure is used.
101
102All procedures also have the side effect when performing dup2 that any
103ports using NEWFD are moved to a different file descriptor and have
104their revealed counts set to zero.
105
106** dup->fdes PORT/FD [NEWFD]
107Returns an integer file descriptor.
108
109** dup->inport PORT/FD [NEWFD]
110Returns a new input port using the new file descriptor.
111
112** dup->outport PORT/FD [NEWFD]
113Returns a new output port using the new file descriptor.
114
115** dup PORT/FD [NEWFD]
116Returns a new port if PORT/FD is a port, with the same mode as the
117supplied port, otherwise returns an integer file descriptor.
118
119** dup->port PORT/FD MODE [NEWFD]
120Returns a new port using the new file descriptor. MODE supplies a
121mode string for the port (as for `open-file').
122
64d01d13
GH
123** port->fdes PORT
124Returns the integer file descriptor underlying PORT. As a
125side effect the revealed count of PORT is incremented.
126
127** fdes->inport FDES
128Returns an existing input port which has FDES as its underlying file
129descriptor, if one exists, and increments its revealed count.
130Otherwise, returns a new input port with a revealed count of 1.
131
132** fdes->outport FDES
133Returns an existing output port which has FDES as its underlying file
134descriptor, if one exists, and increments its revealed count.
135Otherwise, returns a new output port with a revealed count of 1.
136
7a6f1ffa 137** setenv NAME VALUE
956055a9
GH
138If VALUE is `#f', removes NAME from the environment. Otherwise
139adds the string NAME=VALUE to the environment, replacing any previous
140value for NAME.
141
6afcd3b2
GH
142** truncate-file OBJ SIZE
143 Truncates the file referred to by OBJ to at most SIZE bytes. OBJ
144 can be a string containing a file name or an integer file
145 descriptor or port open for output on the file. The underlying
146 system calls are `truncate' and `ftruncate'.
147
148 The return value is unspecified.
149
7a6f1ffa
GH
150** setvbuf PORT MODE [SIZE]
151 Set the buffering mode for PORT. MODE can be:
152 `_IONBF'
153 non-buffered
154
155 `_IOLBF'
156 line buffered
157
158 `_IOFBF'
159 block buffered, using a newly allocated buffer of SIZE bytes.
160 However if SIZE is zero or unspecified, the port will be made
161 non-buffered.
162
163 This procedure should not be used after I/O has been performed with
164 the port.
165
166 Ports are usually block buffered by default, with a default buffer
167 size. Procedures e.g., *Note open-file: File Ports, which accept a
168 mode string allow `0' to be added to request an unbuffered port.
169
6afcd3b2
GH
170** fsync PORT/FD
171 Copies any unwritten data for the specified output file descriptor
172 to disk. If PORT/FD is a port, its buffer is flushed before the
173 underlying file descriptor is fsync'd. The return value is
174 unspecified.
175
176** open-fdes PATH FLAGS [MODES]
177 Similar to `open' but returns a file descriptor instead of a port.
178
179** procedure: execle PATH ENV [ARG] ...
180 Similar to `execl', but the environment of the new process is
181 specified by ENV, which must be a list of strings as returned by
182 the `environ' procedure.
183
184 This procedure is currently implemented using the `execve' system
185 call, but we call it `execle' because of its Scheme calling
186 interface.
187
188** procedure: primitive-exit [STATUS]
189 Terminate the current process without unwinding the Scheme stack.
190 This is would typically be useful after a fork. The exit status
191 is STATUS if supplied, otherwise zero.
192
193** procedure: times
194 Returns an object with information about real and processor time.
195 The following procedures accept such an object as an argument and
196 return a selected component:
197
198 `tms:clock'
199 The current real time, expressed as time units relative to an
200 arbitrary base.
201
202 `tms:utime'
203 The CPU time units used by the calling process.
204
205 `tms:stime'
206 The CPU time units used by the system on behalf of the
207 calling process.
208
209 `tms:cutime'
210 The CPU time units used by terminated child processes of the
211 calling process, whose status has been collected (e.g., using
212 `waitpid').
213
214 `tms:cstime'
215 Similarly, the CPU times units used by the system on behalf of
216 terminated child processes.
7ad3c1e7 217
c484bf7f
JB
218* Changes to the gh_ interface
219
5424b4f7
MD
220** Function: void gh_write (SCM x)
221
222Write the printed representation of the scheme object x to the current
223output port. Corresponds to the scheme level `write'.
224
3a97e020
MD
225** gh_list_length renamed to gh_length.
226
c484bf7f
JB
227* Changes to the scm_ interface
228
5424b4f7
MD
229** Function: SCM scm_internal_stack_catch (SCM tag,
230 scm_catch_body_t body,
231 void *body_data,
232 scm_catch_handler_t handler,
233 void *handler_data)
234
235A new sibling to the other two C level `catch' functions
236scm_internal_catch and scm_internal_lazy_catch. Use it if you want
237the stack to be saved automatically into the variable `the-last-stack'
238(scm_the_last_stack_var) on error. This is necessary if you want to
239use advanced error reporting, such as calling scm_display_error and
240scm_display_backtrace. (They both take a stack object as argument.)
241
88482b31
MD
242** The hook scm_error_callback has been removed. It was originally
243intended as a way for the user to install his own error handler. But
244that method works badly since it intervenes between throw and catch,
245thereby changing the semantics of expressions like (catch #t ...).
246The correct way to do it is to use one of the C level catch functions
247in throw.c: scm_internal_catch/lazy_catch/stack_catch.
248
3a97e020
MD
249** Removed functions:
250
251scm_obj_length, scm_list_length, scm_list_append, scm_list_append_x,
252scm_list_reverse, scm_list_reverse_x
253
254** New macros: SCM_LISTn where n is one of the integers 0-9.
255
256These can be used for pretty list creation from C. The idea is taken
257from Erick Gallesio's STk.
258
298aa6e3
MD
259** scm_array_map renamed to scm_array_map_x
260
c484bf7f
JB
261\f
262Changes in Guile 1.2 (released Tuesday, June 24 1997):
cf78e9e8 263
737c9113
JB
264* Changes to the distribution
265
832b09ed
JB
266** Nightly snapshots are now available from ftp.red-bean.com.
267The old server, ftp.cyclic.com, has been relinquished to its rightful
268owner.
269
270Nightly snapshots of the Guile development sources are now available via
271anonymous FTP from ftp.red-bean.com, as /pub/guile/guile-snap.tar.gz.
272
273Via the web, that's: ftp://ftp.red-bean.com/pub/guile/guile-snap.tar.gz
274For getit, that's: ftp.red-bean.com:/pub/guile/guile-snap.tar.gz
275
0fcab5ed
JB
276** To run Guile without installing it, the procedure has changed a bit.
277
278If you used a separate build directory to compile Guile, you'll need
279to include the build directory in SCHEME_LOAD_PATH, as well as the
280source directory. See the `INSTALL' file for examples.
281
737c9113
JB
282* Changes to the procedure for linking libguile with your programs
283
94982a4e
JB
284** The standard Guile load path for Scheme code now includes
285$(datadir)/guile (usually /usr/local/share/guile). This means that
286you can install your own Scheme files there, and Guile will find them.
287(Previous versions of Guile only checked a directory whose name
288contained the Guile version number, so you had to re-install or move
289your Scheme sources each time you installed a fresh version of Guile.)
290
291The load path also includes $(datadir)/guile/site; we recommend
292putting individual Scheme files there. If you want to install a
293package with multiple source files, create a directory for them under
294$(datadir)/guile.
295
296** Guile 1.2 will now use the Rx regular expression library, if it is
297installed on your system. When you are linking libguile into your own
298programs, this means you will have to link against -lguile, -lqt (if
299you configured Guile with thread support), and -lrx.
27590f82
JB
300
301If you are using autoconf to generate configuration scripts for your
302application, the following lines should suffice to add the appropriate
303libraries to your link command:
304
305### Find Rx, quickthreads and libguile.
306AC_CHECK_LIB(rx, main)
307AC_CHECK_LIB(qt, main)
308AC_CHECK_LIB(guile, scm_shell)
309
94982a4e
JB
310The Guile 1.2 distribution does not contain sources for the Rx
311library, as Guile 1.0 did. If you want to use Rx, you'll need to
312retrieve it from a GNU FTP site and install it separately.
313
b83b8bee
JB
314* Changes to Scheme functions and syntax
315
e035e7e6
MV
316** The dynamic linking features of Guile are now enabled by default.
317You can disable them by giving the `--disable-dynamic-linking' option
318to configure.
319
e035e7e6
MV
320 (dynamic-link FILENAME)
321
322 Find the object file denoted by FILENAME (a string) and link it
323 into the running Guile application. When everything works out,
324 return a Scheme object suitable for representing the linked object
325 file. Otherwise an error is thrown. How object files are
326 searched is system dependent.
327
328 (dynamic-object? VAL)
329
330 Determine whether VAL represents a dynamically linked object file.
331
332 (dynamic-unlink DYNOBJ)
333
334 Unlink the indicated object file from the application. DYNOBJ
335 should be one of the values returned by `dynamic-link'.
336
337 (dynamic-func FUNCTION DYNOBJ)
338
339 Search the C function indicated by FUNCTION (a string or symbol)
340 in DYNOBJ and return some Scheme object that can later be used
341 with `dynamic-call' to actually call this function. Right now,
342 these Scheme objects are formed by casting the address of the
343 function to `long' and converting this number to its Scheme
344 representation.
345
346 (dynamic-call FUNCTION DYNOBJ)
347
348 Call the C function indicated by FUNCTION and DYNOBJ. The
349 function is passed no arguments and its return value is ignored.
350 When FUNCTION is something returned by `dynamic-func', call that
351 function and ignore DYNOBJ. When FUNCTION is a string (or symbol,
352 etc.), look it up in DYNOBJ; this is equivalent to
353
354 (dynamic-call (dynamic-func FUNCTION DYNOBJ) #f)
355
356 Interrupts are deferred while the C function is executing (with
357 SCM_DEFER_INTS/SCM_ALLOW_INTS).
358
359 (dynamic-args-call FUNCTION DYNOBJ ARGS)
360
361 Call the C function indicated by FUNCTION and DYNOBJ, but pass it
362 some arguments and return its return value. The C function is
363 expected to take two arguments and return an `int', just like
364 `main':
365
366 int c_func (int argc, char **argv);
367
368 ARGS must be a list of strings and is converted into an array of
369 `char *'. The array is passed in ARGV and its size in ARGC. The
370 return value is converted to a Scheme number and returned from the
371 call to `dynamic-args-call'.
372
0fcab5ed
JB
373When dynamic linking is disabled or not supported on your system,
374the above functions throw errors, but they are still available.
375
e035e7e6
MV
376Here is a small example that works on GNU/Linux:
377
378 (define libc-obj (dynamic-link "libc.so"))
379 (dynamic-args-call 'rand libc-obj '())
380
381See the file `libguile/DYNAMIC-LINKING' for additional comments.
382
27590f82
JB
383** The #/ syntax for module names is depreciated, and will be removed
384in a future version of Guile. Instead of
385
386 #/foo/bar/baz
387
388instead write
389
390 (foo bar baz)
391
392The latter syntax is more consistent with existing Lisp practice.
393
5dade857
MV
394** Guile now does fancier printing of structures. Structures are the
395underlying implementation for records, which in turn are used to
396implement modules, so all of these object now print differently and in
397a more informative way.
398
161029df
JB
399The Scheme printer will examine the builtin variable *struct-printer*
400whenever it needs to print a structure object. When this variable is
401not `#f' it is deemed to be a procedure and will be applied to the
402structure object and the output port. When *struct-printer* is `#f'
403or the procedure return `#f' the structure object will be printed in
404the boring #<struct 80458270> form.
5dade857
MV
405
406This hook is used by some routines in ice-9/boot-9.scm to implement
407type specific printing routines. Please read the comments there about
408"printing structs".
409
410One of the more specific uses of structs are records. The printing
411procedure that could be passed to MAKE-RECORD-TYPE is now actually
412called. It should behave like a *struct-printer* procedure (described
413above).
414
b83b8bee
JB
415** Guile now supports a new R4RS-compliant syntax for keywords. A
416token of the form #:NAME, where NAME has the same syntax as a Scheme
417symbol, is the external representation of the keyword named NAME.
418Keyword objects print using this syntax as well, so values containing
1e5afba0
JB
419keyword objects can be read back into Guile. When used in an
420expression, keywords are self-quoting objects.
b83b8bee
JB
421
422Guile suports this read syntax, and uses this print syntax, regardless
423of the current setting of the `keyword' read option. The `keyword'
424read option only controls whether Guile recognizes the `:NAME' syntax,
425which is incompatible with R4RS. (R4RS says such token represent
426symbols.)
737c9113
JB
427
428** Guile has regular expression support again. Guile 1.0 included
429functions for matching regular expressions, based on the Rx library.
430In Guile 1.1, the Guile/Rx interface was removed to simplify the
431distribution, and thus Guile had no regular expression support. Guile
94982a4e
JB
4321.2 again supports the most commonly used functions, and supports all
433of SCSH's regular expression functions.
2409cdfa 434
94982a4e
JB
435If your system does not include a POSIX regular expression library,
436and you have not linked Guile with a third-party regexp library such as
437Rx, these functions will not be available. You can tell whether your
438Guile installation includes regular expression support by checking
439whether the `*features*' list includes the `regex' symbol.
737c9113 440
94982a4e 441*** regexp functions
161029df 442
94982a4e
JB
443By default, Guile supports POSIX extended regular expressions. That
444means that the characters `(', `)', `+' and `?' are special, and must
445be escaped if you wish to match the literal characters.
e1a191a8 446
94982a4e
JB
447This regular expression interface was modeled after that implemented
448by SCSH, the Scheme Shell. It is intended to be upwardly compatible
449with SCSH regular expressions.
450
451**** Function: string-match PATTERN STR [START]
452 Compile the string PATTERN into a regular expression and compare
453 it with STR. The optional numeric argument START specifies the
454 position of STR at which to begin matching.
455
456 `string-match' returns a "match structure" which describes what,
457 if anything, was matched by the regular expression. *Note Match
458 Structures::. If STR does not match PATTERN at all,
459 `string-match' returns `#f'.
460
461 Each time `string-match' is called, it must compile its PATTERN
462argument into a regular expression structure. This operation is
463expensive, which makes `string-match' inefficient if the same regular
464expression is used several times (for example, in a loop). For better
465performance, you can compile a regular expression in advance and then
466match strings against the compiled regexp.
467
468**** Function: make-regexp STR [FLAGS]
469 Compile the regular expression described by STR, and return the
470 compiled regexp structure. If STR does not describe a legal
471 regular expression, `make-regexp' throws a
472 `regular-expression-syntax' error.
473
474 FLAGS may be the bitwise-or of one or more of the following:
475
476**** Constant: regexp/extended
477 Use POSIX Extended Regular Expression syntax when interpreting
478 STR. If not set, POSIX Basic Regular Expression syntax is used.
479 If the FLAGS argument is omitted, we assume regexp/extended.
480
481**** Constant: regexp/icase
482 Do not differentiate case. Subsequent searches using the
483 returned regular expression will be case insensitive.
484
485**** Constant: regexp/newline
486 Match-any-character operators don't match a newline.
487
488 A non-matching list ([^...]) not containing a newline matches a
489 newline.
490
491 Match-beginning-of-line operator (^) matches the empty string
492 immediately after a newline, regardless of whether the FLAGS
493 passed to regexp-exec contain regexp/notbol.
494
495 Match-end-of-line operator ($) matches the empty string
496 immediately before a newline, regardless of whether the FLAGS
497 passed to regexp-exec contain regexp/noteol.
498
499**** Function: regexp-exec REGEXP STR [START [FLAGS]]
500 Match the compiled regular expression REGEXP against `str'. If
501 the optional integer START argument is provided, begin matching
502 from that position in the string. Return a match structure
503 describing the results of the match, or `#f' if no match could be
504 found.
505
506 FLAGS may be the bitwise-or of one or more of the following:
507
508**** Constant: regexp/notbol
509 The match-beginning-of-line operator always fails to match (but
510 see the compilation flag regexp/newline above) This flag may be
511 used when different portions of a string are passed to
512 regexp-exec and the beginning of the string should not be
513 interpreted as the beginning of the line.
514
515**** Constant: regexp/noteol
516 The match-end-of-line operator always fails to match (but see the
517 compilation flag regexp/newline above)
518
519**** Function: regexp? OBJ
520 Return `#t' if OBJ is a compiled regular expression, or `#f'
521 otherwise.
522
523 Regular expressions are commonly used to find patterns in one string
524and replace them with the contents of another string.
525
526**** Function: regexp-substitute PORT MATCH [ITEM...]
527 Write to the output port PORT selected contents of the match
528 structure MATCH. Each ITEM specifies what should be written, and
529 may be one of the following arguments:
530
531 * A string. String arguments are written out verbatim.
532
533 * An integer. The submatch with that number is written.
534
535 * The symbol `pre'. The portion of the matched string preceding
536 the regexp match is written.
537
538 * The symbol `post'. The portion of the matched string
539 following the regexp match is written.
540
541 PORT may be `#f', in which case nothing is written; instead,
542 `regexp-substitute' constructs a string from the specified ITEMs
543 and returns that.
544
545**** Function: regexp-substitute/global PORT REGEXP TARGET [ITEM...]
546 Similar to `regexp-substitute', but can be used to perform global
547 substitutions on STR. Instead of taking a match structure as an
548 argument, `regexp-substitute/global' takes two string arguments: a
549 REGEXP string describing a regular expression, and a TARGET string
550 which should be matched against this regular expression.
551
552 Each ITEM behaves as in REGEXP-SUBSTITUTE, with the following
553 exceptions:
554
555 * A function may be supplied. When this function is called, it
556 will be passed one argument: a match structure for a given
557 regular expression match. It should return a string to be
558 written out to PORT.
559
560 * The `post' symbol causes `regexp-substitute/global' to recurse
561 on the unmatched portion of STR. This *must* be supplied in
562 order to perform global search-and-replace on STR; if it is
563 not present among the ITEMs, then `regexp-substitute/global'
564 will return after processing a single match.
565
566*** Match Structures
567
568 A "match structure" is the object returned by `string-match' and
569`regexp-exec'. It describes which portion of a string, if any, matched
570the given regular expression. Match structures include: a reference to
571the string that was checked for matches; the starting and ending
572positions of the regexp match; and, if the regexp included any
573parenthesized subexpressions, the starting and ending positions of each
574submatch.
575
576 In each of the regexp match functions described below, the `match'
577argument must be a match structure returned by a previous call to
578`string-match' or `regexp-exec'. Most of these functions return some
579information about the original target string that was matched against a
580regular expression; we will call that string TARGET for easy reference.
581
582**** Function: regexp-match? OBJ
583 Return `#t' if OBJ is a match structure returned by a previous
584 call to `regexp-exec', or `#f' otherwise.
585
586**** Function: match:substring MATCH [N]
587 Return the portion of TARGET matched by subexpression number N.
588 Submatch 0 (the default) represents the entire regexp match. If
589 the regular expression as a whole matched, but the subexpression
590 number N did not match, return `#f'.
591
592**** Function: match:start MATCH [N]
593 Return the starting position of submatch number N.
594
595**** Function: match:end MATCH [N]
596 Return the ending position of submatch number N.
597
598**** Function: match:prefix MATCH
599 Return the unmatched portion of TARGET preceding the regexp match.
600
601**** Function: match:suffix MATCH
602 Return the unmatched portion of TARGET following the regexp match.
603
604**** Function: match:count MATCH
605 Return the number of parenthesized subexpressions from MATCH.
606 Note that the entire regular expression match itself counts as a
607 subexpression, and failed submatches are included in the count.
608
609**** Function: match:string MATCH
610 Return the original TARGET string.
611
612*** Backslash Escapes
613
614 Sometimes you will want a regexp to match characters like `*' or `$'
615exactly. For example, to check whether a particular string represents
616a menu entry from an Info node, it would be useful to match it against
617a regexp like `^* [^:]*::'. However, this won't work; because the
618asterisk is a metacharacter, it won't match the `*' at the beginning of
619the string. In this case, we want to make the first asterisk un-magic.
620
621 You can do this by preceding the metacharacter with a backslash
622character `\'. (This is also called "quoting" the metacharacter, and
623is known as a "backslash escape".) When Guile sees a backslash in a
624regular expression, it considers the following glyph to be an ordinary
625character, no matter what special meaning it would ordinarily have.
626Therefore, we can make the above example work by changing the regexp to
627`^\* [^:]*::'. The `\*' sequence tells the regular expression engine
628to match only a single asterisk in the target string.
629
630 Since the backslash is itself a metacharacter, you may force a
631regexp to match a backslash in the target string by preceding the
632backslash with itself. For example, to find variable references in a
633TeX program, you might want to find occurrences of the string `\let\'
634followed by any number of alphabetic characters. The regular expression
635`\\let\\[A-Za-z]*' would do this: the double backslashes in the regexp
636each match a single backslash in the target string.
637
638**** Function: regexp-quote STR
639 Quote each special character found in STR with a backslash, and
640 return the resulting string.
641
642 *Very important:* Using backslash escapes in Guile source code (as
643in Emacs Lisp or C) can be tricky, because the backslash character has
644special meaning for the Guile reader. For example, if Guile encounters
645the character sequence `\n' in the middle of a string while processing
646Scheme code, it replaces those characters with a newline character.
647Similarly, the character sequence `\t' is replaced by a horizontal tab.
648Several of these "escape sequences" are processed by the Guile reader
649before your code is executed. Unrecognized escape sequences are
650ignored: if the characters `\*' appear in a string, they will be
651translated to the single character `*'.
652
653 This translation is obviously undesirable for regular expressions,
654since we want to be able to include backslashes in a string in order to
655escape regexp metacharacters. Therefore, to make sure that a backslash
656is preserved in a string in your Guile program, you must use *two*
657consecutive backslashes:
658
659 (define Info-menu-entry-pattern (make-regexp "^\\* [^:]*"))
660
661 The string in this example is preprocessed by the Guile reader before
662any code is executed. The resulting argument to `make-regexp' is the
663string `^\* [^:]*', which is what we really want.
664
665 This also means that in order to write a regular expression that
666matches a single backslash character, the regular expression string in
667the source code must include *four* backslashes. Each consecutive pair
668of backslashes gets translated by the Guile reader to a single
669backslash, and the resulting double-backslash is interpreted by the
670regexp engine as matching a single backslash character. Hence:
671
672 (define tex-variable-pattern (make-regexp "\\\\let\\\\=[A-Za-z]*"))
673
674 The reason for the unwieldiness of this syntax is historical. Both
675regular expression pattern matchers and Unix string processing systems
676have traditionally used backslashes with the special meanings described
677above. The POSIX regular expression specification and ANSI C standard
678both require these semantics. Attempting to abandon either convention
679would cause other kinds of compatibility problems, possibly more severe
680ones. Therefore, without extending the Scheme reader to support
681strings with different quoting conventions (an ungainly and confusing
682extension when implemented in other languages), we must adhere to this
683cumbersome escape syntax.
684
7ad3c1e7
GH
685* Changes to the gh_ interface
686
687* Changes to the scm_ interface
688
689* Changes to system call interfaces:
94982a4e 690
7ad3c1e7 691** The value returned by `raise' is now unspecified. It throws an exception
e1a191a8
GH
692if an error occurs.
693
94982a4e 694*** A new procedure `sigaction' can be used to install signal handlers
115b09a5
GH
695
696(sigaction signum [action] [flags])
697
698signum is the signal number, which can be specified using the value
699of SIGINT etc.
700
701If action is omitted, sigaction returns a pair: the CAR is the current
702signal hander, which will be either an integer with the value SIG_DFL
703(default action) or SIG_IGN (ignore), or the Scheme procedure which
704handles the signal, or #f if a non-Scheme procedure handles the
705signal. The CDR contains the current sigaction flags for the handler.
706
707If action is provided, it is installed as the new handler for signum.
708action can be a Scheme procedure taking one argument, or the value of
709SIG_DFL (default action) or SIG_IGN (ignore), or #f to restore
710whatever signal handler was installed before sigaction was first used.
711Flags can optionally be specified for the new handler (SA_RESTART is
712always used if the system provides it, so need not be specified.) The
713return value is a pair with information about the old handler as
714described above.
715
716This interface does not provide access to the "signal blocking"
717facility. Maybe this is not needed, since the thread support may
718provide solutions to the problem of consistent access to data
719structures.
e1a191a8 720
94982a4e 721*** A new procedure `flush-all-ports' is equivalent to running
89ea5b7c
GH
722`force-output' on every port open for output.
723
94982a4e
JB
724** Guile now provides information on how it was built, via the new
725global variable, %guile-build-info. This variable records the values
726of the standard GNU makefile directory variables as an assocation
727list, mapping variable names (symbols) onto directory paths (strings).
728For example, to find out where the Guile link libraries were
729installed, you can say:
730
731guile -c "(display (assq-ref %guile-build-info 'libdir)) (newline)"
732
733
734* Changes to the scm_ interface
735
736** The new function scm_handle_by_message_noexit is just like the
737existing scm_handle_by_message function, except that it doesn't call
738exit to terminate the process. Instead, it prints a message and just
739returns #f. This might be a more appropriate catch-all handler for
740new dynamic roots and threads.
741
cf78e9e8 742\f
c484bf7f 743Changes in Guile 1.1 (released Friday, May 16 1997):
f3b1485f
JB
744
745* Changes to the distribution.
746
747The Guile 1.0 distribution has been split up into several smaller
748pieces:
749guile-core --- the Guile interpreter itself.
750guile-tcltk --- the interface between the Guile interpreter and
751 Tcl/Tk; Tcl is an interpreter for a stringy language, and Tk
752 is a toolkit for building graphical user interfaces.
753guile-rgx-ctax --- the interface between Guile and the Rx regular
754 expression matcher, and the translator for the Ctax
755 programming language. These are packaged together because the
756 Ctax translator uses Rx to parse Ctax source code.
757
095936d2
JB
758This NEWS file describes the changes made to guile-core since the 1.0
759release.
760
48d224d7
JB
761We no longer distribute the documentation, since it was either out of
762date, or incomplete. As soon as we have current documentation, we
763will distribute it.
764
0fcab5ed
JB
765
766
f3b1485f
JB
767* Changes to the stand-alone interpreter
768
48d224d7
JB
769** guile now accepts command-line arguments compatible with SCSH, Olin
770Shivers' Scheme Shell.
771
772In general, arguments are evaluated from left to right, but there are
773exceptions. The following switches stop argument processing, and
774stash all remaining command-line arguments as the value returned by
775the (command-line) function.
776 -s SCRIPT load Scheme source code from FILE, and exit
777 -c EXPR evalute Scheme expression EXPR, and exit
778 -- stop scanning arguments; run interactively
779
780The switches below are processed as they are encountered.
781 -l FILE load Scheme source code from FILE
782 -e FUNCTION after reading script, apply FUNCTION to
783 command line arguments
784 -ds do -s script at this point
785 --emacs enable Emacs protocol (experimental)
786 -h, --help display this help and exit
787 -v, --version display version information and exit
788 \ read arguments from following script lines
789
790So, for example, here is a Guile script named `ekko' (thanks, Olin)
791which re-implements the traditional "echo" command:
792
793#!/usr/local/bin/guile -s
794!#
795(define (main args)
796 (map (lambda (arg) (display arg) (display " "))
797 (cdr args))
798 (newline))
799
800(main (command-line))
801
802Suppose we invoke this script as follows:
803
804 ekko a speckled gecko
805
806Through the magic of Unix script processing (triggered by the `#!'
807token at the top of the file), /usr/local/bin/guile receives the
808following list of command-line arguments:
809
810 ("-s" "./ekko" "a" "speckled" "gecko")
811
812Unix inserts the name of the script after the argument specified on
813the first line of the file (in this case, "-s"), and then follows that
814with the arguments given to the script. Guile loads the script, which
815defines the `main' function, and then applies it to the list of
816remaining command-line arguments, ("a" "speckled" "gecko").
817
095936d2
JB
818In Unix, the first line of a script file must take the following form:
819
820#!INTERPRETER ARGUMENT
821
822where INTERPRETER is the absolute filename of the interpreter
823executable, and ARGUMENT is a single command-line argument to pass to
824the interpreter.
825
826You may only pass one argument to the interpreter, and its length is
827limited. These restrictions can be annoying to work around, so Guile
828provides a general mechanism (borrowed from, and compatible with,
829SCSH) for circumventing them.
830
831If the ARGUMENT in a Guile script is a single backslash character,
832`\', Guile will open the script file, parse arguments from its second
833and subsequent lines, and replace the `\' with them. So, for example,
834here is another implementation of the `ekko' script:
835
836#!/usr/local/bin/guile \
837-e main -s
838!#
839(define (main args)
840 (for-each (lambda (arg) (display arg) (display " "))
841 (cdr args))
842 (newline))
843
844If the user invokes this script as follows:
845
846 ekko a speckled gecko
847
848Unix expands this into
849
850 /usr/local/bin/guile \ ekko a speckled gecko
851
852When Guile sees the `\' argument, it replaces it with the arguments
853read from the second line of the script, producing:
854
855 /usr/local/bin/guile -e main -s ekko a speckled gecko
856
857This tells Guile to load the `ekko' script, and apply the function
858`main' to the argument list ("a" "speckled" "gecko").
859
860Here is how Guile parses the command-line arguments:
861- Each space character terminates an argument. This means that two
862 spaces in a row introduce an empty-string argument.
863- The tab character is not permitted (unless you quote it with the
864 backslash character, as described below), to avoid confusion.
865- The newline character terminates the sequence of arguments, and will
866 also terminate a final non-empty argument. (However, a newline
867 following a space will not introduce a final empty-string argument;
868 it only terminates the argument list.)
869- The backslash character is the escape character. It escapes
870 backslash, space, tab, and newline. The ANSI C escape sequences
871 like \n and \t are also supported. These produce argument
872 constituents; the two-character combination \n doesn't act like a
873 terminating newline. The escape sequence \NNN for exactly three
874 octal digits reads as the character whose ASCII code is NNN. As
875 above, characters produced this way are argument constituents.
876 Backslash followed by other characters is not allowed.
877
48d224d7
JB
878* Changes to the procedure for linking libguile with your programs
879
880** Guile now builds and installs a shared guile library, if your
881system support shared libraries. (It still builds a static library on
882all systems.) Guile automatically detects whether your system
883supports shared libraries. To prevent Guile from buildisg shared
884libraries, pass the `--disable-shared' flag to the configure script.
885
886Guile takes longer to compile when it builds shared libraries, because
887it must compile every file twice --- once to produce position-
888independent object code, and once to produce normal object code.
889
890** The libthreads library has been merged into libguile.
891
892To link a program against Guile, you now need only link against
893-lguile and -lqt; -lthreads is no longer needed. If you are using
894autoconf to generate configuration scripts for your application, the
895following lines should suffice to add the appropriate libraries to
896your link command:
897
898### Find quickthreads and libguile.
899AC_CHECK_LIB(qt, main)
900AC_CHECK_LIB(guile, scm_shell)
f3b1485f
JB
901
902* Changes to Scheme functions
903
095936d2
JB
904** Guile Scheme's special syntax for keyword objects is now optional,
905and disabled by default.
906
907The syntax variation from R4RS made it difficult to port some
908interesting packages to Guile. The routines which accepted keyword
909arguments (mostly in the module system) have been modified to also
910accept symbols whose names begin with `:'.
911
912To change the keyword syntax, you must first import the (ice-9 debug)
913module:
914 (use-modules (ice-9 debug))
915
916Then you can enable the keyword syntax as follows:
917 (read-set! keywords 'prefix)
918
919To disable keyword syntax, do this:
920 (read-set! keywords #f)
921
922** Many more primitive functions accept shared substrings as
923arguments. In the past, these functions required normal, mutable
924strings as arguments, although they never made use of this
925restriction.
926
927** The uniform array functions now operate on byte vectors. These
928functions are `array-fill!', `serial-array-copy!', `array-copy!',
929`serial-array-map', `array-map', `array-for-each', and
930`array-index-map!'.
931
932** The new functions `trace' and `untrace' implement simple debugging
933support for Scheme functions.
934
935The `trace' function accepts any number of procedures as arguments,
936and tells the Guile interpreter to display each procedure's name and
937arguments each time the procedure is invoked. When invoked with no
938arguments, `trace' returns the list of procedures currently being
939traced.
940
941The `untrace' function accepts any number of procedures as arguments,
942and tells the Guile interpreter not to trace them any more. When
943invoked with no arguments, `untrace' untraces all curretly traced
944procedures.
945
946The tracing in Guile has an advantage over most other systems: we
947don't create new procedure objects, but mark the procedure objects
948themselves. This means that anonymous and internal procedures can be
949traced.
950
951** The function `assert-repl-prompt' has been renamed to
952`set-repl-prompt!'. It takes one argument, PROMPT.
953- If PROMPT is #f, the Guile read-eval-print loop will not prompt.
954- If PROMPT is a string, we use it as a prompt.
955- If PROMPT is a procedure accepting no arguments, we call it, and
956 display the result as a prompt.
957- Otherwise, we display "> ".
958
959** The new function `eval-string' reads Scheme expressions from a
960string and evaluates them, returning the value of the last expression
961in the string. If the string contains no expressions, it returns an
962unspecified value.
963
964** The new function `thunk?' returns true iff its argument is a
965procedure of zero arguments.
966
967** `defined?' is now a builtin function, instead of syntax. This
968means that its argument should be quoted. It returns #t iff its
969argument is bound in the current module.
970
971** The new syntax `use-modules' allows you to add new modules to your
972environment without re-typing a complete `define-module' form. It
973accepts any number of module names as arguments, and imports their
974public bindings into the current module.
975
976** The new function (module-defined? NAME MODULE) returns true iff
977NAME, a symbol, is defined in MODULE, a module object.
978
979** The new function `builtin-bindings' creates and returns a hash
980table containing copies of all the root module's bindings.
981
982** The new function `builtin-weak-bindings' does the same as
983`builtin-bindings', but creates a doubly-weak hash table.
984
985** The `equal?' function now considers variable objects to be
986equivalent if they have the same name and the same value.
987
988** The new function `command-line' returns the command-line arguments
989given to Guile, as a list of strings.
990
991When using guile as a script interpreter, `command-line' returns the
992script's arguments; those processed by the interpreter (like `-s' or
993`-c') are omitted. (In other words, you get the normal, expected
994behavior.) Any application that uses scm_shell to process its
995command-line arguments gets this behavior as well.
996
997** The new function `load-user-init' looks for a file called `.guile'
998in the user's home directory, and loads it if it exists. This is
999mostly for use by the code generated by scm_compile_shell_switches,
1000but we thought it might also be useful in other circumstances.
1001
1002** The new function `log10' returns the base-10 logarithm of its
1003argument.
1004
1005** Changes to I/O functions
1006
1007*** The functions `read', `primitive-load', `read-and-eval!', and
1008`primitive-load-path' no longer take optional arguments controlling
1009case insensitivity and a `#' parser.
1010
1011Case sensitivity is now controlled by a read option called
1012`case-insensitive'. The user can add new `#' syntaxes with the
1013`read-hash-extend' function (see below).
1014
1015*** The new function `read-hash-extend' allows the user to change the
1016syntax of Guile Scheme in a somewhat controlled way.
1017
1018(read-hash-extend CHAR PROC)
1019 When parsing S-expressions, if we read a `#' character followed by
1020 the character CHAR, use PROC to parse an object from the stream.
1021 If PROC is #f, remove any parsing procedure registered for CHAR.
1022
1023 The reader applies PROC to two arguments: CHAR and an input port.
1024
1025*** The new functions read-delimited and read-delimited! provide a
1026general mechanism for doing delimited input on streams.
1027
1028(read-delimited DELIMS [PORT HANDLE-DELIM])
1029 Read until we encounter one of the characters in DELIMS (a string),
1030 or end-of-file. PORT is the input port to read from; it defaults to
1031 the current input port. The HANDLE-DELIM parameter determines how
1032 the terminating character is handled; it should be one of the
1033 following symbols:
1034
1035 'trim omit delimiter from result
1036 'peek leave delimiter character in input stream
1037 'concat append delimiter character to returned value
1038 'split return a pair: (RESULT . TERMINATOR)
1039
1040 HANDLE-DELIM defaults to 'peek.
1041
1042(read-delimited! DELIMS BUF [PORT HANDLE-DELIM START END])
1043 A side-effecting variant of `read-delimited'.
1044
1045 The data is written into the string BUF at the indices in the
1046 half-open interval [START, END); the default interval is the whole
1047 string: START = 0 and END = (string-length BUF). The values of
1048 START and END must specify a well-defined interval in BUF, i.e.
1049 0 <= START <= END <= (string-length BUF).
1050
1051 It returns NBYTES, the number of bytes read. If the buffer filled
1052 up without a delimiter character being found, it returns #f. If the
1053 port is at EOF when the read starts, it returns the EOF object.
1054
1055 If an integer is returned (i.e., the read is successfully terminated
1056 by reading a delimiter character), then the HANDLE-DELIM parameter
1057 determines how to handle the terminating character. It is described
1058 above, and defaults to 'peek.
1059
1060(The descriptions of these functions were borrowed from the SCSH
1061manual, by Olin Shivers and Brian Carlstrom.)
1062
1063*** The `%read-delimited!' function is the primitive used to implement
1064`read-delimited' and `read-delimited!'.
1065
1066(%read-delimited! DELIMS BUF GOBBLE? [PORT START END])
1067
1068This returns a pair of values: (TERMINATOR . NUM-READ).
1069- TERMINATOR describes why the read was terminated. If it is a
1070 character or the eof object, then that is the value that terminated
1071 the read. If it is #f, the function filled the buffer without finding
1072 a delimiting character.
1073- NUM-READ is the number of characters read into BUF.
1074
1075If the read is successfully terminated by reading a delimiter
1076character, then the gobble? parameter determines what to do with the
1077terminating character. If true, the character is removed from the
1078input stream; if false, the character is left in the input stream
1079where a subsequent read operation will retrieve it. In either case,
1080the character is also the first value returned by the procedure call.
1081
1082(The descriptions of this function was borrowed from the SCSH manual,
1083by Olin Shivers and Brian Carlstrom.)
1084
1085*** The `read-line' and `read-line!' functions have changed; they now
1086trim the terminator by default; previously they appended it to the
1087returned string. For the old behavior, use (read-line PORT 'concat).
1088
1089*** The functions `uniform-array-read!' and `uniform-array-write!' now
1090take new optional START and END arguments, specifying the region of
1091the array to read and write.
1092
f348c807
JB
1093*** The `ungetc-char-ready?' function has been removed. We feel it's
1094inappropriate for an interface to expose implementation details this
1095way.
095936d2
JB
1096
1097** Changes to the Unix library and system call interface
1098
1099*** The new fcntl function provides access to the Unix `fcntl' system
1100call.
1101
1102(fcntl PORT COMMAND VALUE)
1103 Apply COMMAND to PORT's file descriptor, with VALUE as an argument.
1104 Values for COMMAND are:
1105
1106 F_DUPFD duplicate a file descriptor
1107 F_GETFD read the descriptor's close-on-exec flag
1108 F_SETFD set the descriptor's close-on-exec flag to VALUE
1109 F_GETFL read the descriptor's flags, as set on open
1110 F_SETFL set the descriptor's flags, as set on open to VALUE
1111 F_GETOWN return the process ID of a socket's owner, for SIGIO
1112 F_SETOWN set the process that owns a socket to VALUE, for SIGIO
1113 FD_CLOEXEC not sure what this is
1114
1115For details, see the documentation for the fcntl system call.
1116
1117*** The arguments to `select' have changed, for compatibility with
1118SCSH. The TIMEOUT parameter may now be non-integral, yielding the
1119expected behavior. The MILLISECONDS parameter has been changed to
1120MICROSECONDS, to more closely resemble the underlying system call.
1121The RVEC, WVEC, and EVEC arguments can now be vectors; the type of the
1122corresponding return set will be the same.
1123
1124*** The arguments to the `mknod' system call have changed. They are
1125now:
1126
1127(mknod PATH TYPE PERMS DEV)
1128 Create a new file (`node') in the file system. PATH is the name of
1129 the file to create. TYPE is the kind of file to create; it should
1130 be 'fifo, 'block-special, or 'char-special. PERMS specifies the
1131 permission bits to give the newly created file. If TYPE is
1132 'block-special or 'char-special, DEV specifies which device the
1133 special file refers to; its interpretation depends on the kind of
1134 special file being created.
1135
1136*** The `fork' function has been renamed to `primitive-fork', to avoid
1137clashing with various SCSH forks.
1138
1139*** The `recv' and `recvfrom' functions have been renamed to `recv!'
1140and `recvfrom!'. They no longer accept a size for a second argument;
1141you must pass a string to hold the received value. They no longer
1142return the buffer. Instead, `recv' returns the length of the message
1143received, and `recvfrom' returns a pair containing the packet's length
1144and originating address.
1145
1146*** The file descriptor datatype has been removed, as have the
1147`read-fd', `write-fd', `close', `lseek', and `dup' functions.
1148We plan to replace these functions with a SCSH-compatible interface.
1149
1150*** The `create' function has been removed; it's just a special case
1151of `open'.
1152
1153*** There are new functions to break down process termination status
1154values. In the descriptions below, STATUS is a value returned by
1155`waitpid'.
1156
1157(status:exit-val STATUS)
1158 If the child process exited normally, this function returns the exit
1159 code for the child process (i.e., the value passed to exit, or
1160 returned from main). If the child process did not exit normally,
1161 this function returns #f.
1162
1163(status:stop-sig STATUS)
1164 If the child process was suspended by a signal, this function
1165 returns the signal that suspended the child. Otherwise, it returns
1166 #f.
1167
1168(status:term-sig STATUS)
1169 If the child process terminated abnormally, this function returns
1170 the signal that terminated the child. Otherwise, this function
1171 returns false.
1172
1173POSIX promises that exactly one of these functions will return true on
1174a valid STATUS value.
1175
1176These functions are compatible with SCSH.
1177
1178*** There are new accessors and setters for the broken-out time vectors
48d224d7
JB
1179returned by `localtime', `gmtime', and that ilk. They are:
1180
1181 Component Accessor Setter
1182 ========================= ============ ============
1183 seconds tm:sec set-tm:sec
1184 minutes tm:min set-tm:min
1185 hours tm:hour set-tm:hour
1186 day of the month tm:mday set-tm:mday
1187 month tm:mon set-tm:mon
1188 year tm:year set-tm:year
1189 day of the week tm:wday set-tm:wday
1190 day in the year tm:yday set-tm:yday
1191 daylight saving time tm:isdst set-tm:isdst
1192 GMT offset, seconds tm:gmtoff set-tm:gmtoff
1193 name of time zone tm:zone set-tm:zone
1194
095936d2
JB
1195*** There are new accessors for the vectors returned by `uname',
1196describing the host system:
48d224d7
JB
1197
1198 Component Accessor
1199 ============================================== ================
1200 name of the operating system implementation utsname:sysname
1201 network name of this machine utsname:nodename
1202 release level of the operating system utsname:release
1203 version level of the operating system utsname:version
1204 machine hardware platform utsname:machine
1205
095936d2
JB
1206*** There are new accessors for the vectors returned by `getpw',
1207`getpwnam', `getpwuid', and `getpwent', describing entries from the
1208system's user database:
1209
1210 Component Accessor
1211 ====================== =================
1212 user name passwd:name
1213 user password passwd:passwd
1214 user id passwd:uid
1215 group id passwd:gid
1216 real name passwd:gecos
1217 home directory passwd:dir
1218 shell program passwd:shell
1219
1220*** There are new accessors for the vectors returned by `getgr',
1221`getgrnam', `getgrgid', and `getgrent', describing entries from the
1222system's group database:
1223
1224 Component Accessor
1225 ======================= ============
1226 group name group:name
1227 group password group:passwd
1228 group id group:gid
1229 group members group:mem
1230
1231*** There are new accessors for the vectors returned by `gethost',
1232`gethostbyaddr', `gethostbyname', and `gethostent', describing
1233internet hosts:
1234
1235 Component Accessor
1236 ========================= ===============
1237 official name of host hostent:name
1238 alias list hostent:aliases
1239 host address type hostent:addrtype
1240 length of address hostent:length
1241 list of addresses hostent:addr-list
1242
1243*** There are new accessors for the vectors returned by `getnet',
1244`getnetbyaddr', `getnetbyname', and `getnetent', describing internet
1245networks:
1246
1247 Component Accessor
1248 ========================= ===============
1249 official name of net netent:name
1250 alias list netent:aliases
1251 net number type netent:addrtype
1252 net number netent:net
1253
1254*** There are new accessors for the vectors returned by `getproto',
1255`getprotobyname', `getprotobynumber', and `getprotoent', describing
1256internet protocols:
1257
1258 Component Accessor
1259 ========================= ===============
1260 official protocol name protoent:name
1261 alias list protoent:aliases
1262 protocol number protoent:proto
1263
1264*** There are new accessors for the vectors returned by `getserv',
1265`getservbyname', `getservbyport', and `getservent', describing
1266internet protocols:
1267
1268 Component Accessor
1269 ========================= ===============
1270 official service name servent:name
1271 alias list servent:aliases
1272 port number servent:port
1273 protocol to use servent:proto
1274
1275*** There are new accessors for the sockaddr structures returned by
1276`accept', `getsockname', `getpeername', `recvfrom!':
1277
1278 Component Accessor
1279 ======================================== ===============
1280 address format (`family') sockaddr:fam
1281 path, for file domain addresses sockaddr:path
1282 address, for internet domain addresses sockaddr:addr
1283 TCP or UDP port, for internet sockaddr:port
1284
1285*** The `getpwent', `getgrent', `gethostent', `getnetent',
1286`getprotoent', and `getservent' functions now return #f at the end of
1287the user database. (They used to throw an exception.)
1288
1289Note that calling MUMBLEent function is equivalent to calling the
1290corresponding MUMBLE function with no arguments.
1291
1292*** The `setpwent', `setgrent', `sethostent', `setnetent',
1293`setprotoent', and `setservent' routines now take no arguments.
1294
1295*** The `gethost', `getproto', `getnet', and `getserv' functions now
1296provide more useful information when they throw an exception.
1297
1298*** The `lnaof' function has been renamed to `inet-lnaof'.
1299
1300*** Guile now claims to have the `current-time' feature.
1301
1302*** The `mktime' function now takes an optional second argument ZONE,
1303giving the time zone to use for the conversion. ZONE should be a
1304string, in the same format as expected for the "TZ" environment variable.
1305
1306*** The `strptime' function now returns a pair (TIME . COUNT), where
1307TIME is the parsed time as a vector, and COUNT is the number of
1308characters from the string left unparsed. This function used to
1309return the remaining characters as a string.
1310
1311*** The `gettimeofday' function has replaced the old `time+ticks' function.
1312The return value is now (SECONDS . MICROSECONDS); the fractional
1313component is no longer expressed in "ticks".
1314
1315*** The `ticks/sec' constant has been removed, in light of the above change.
6685dc83 1316
ea00ecba
MG
1317* Changes to the gh_ interface
1318
1319** gh_eval_str() now returns an SCM object which is the result of the
1320evaluation
1321
aaef0d2a
MG
1322** gh_scm2str() now copies the Scheme data to a caller-provided C
1323array
1324
1325** gh_scm2newstr() now makes a C array, copies the Scheme data to it,
1326and returns the array
1327
1328** gh_scm2str0() is gone: there is no need to distinguish
1329null-terminated from non-null-terminated, since gh_scm2newstr() allows
1330the user to interpret the data both ways.
1331
f3b1485f
JB
1332* Changes to the scm_ interface
1333
095936d2
JB
1334** The new function scm_symbol_value0 provides an easy way to get a
1335symbol's value from C code:
1336
1337SCM scm_symbol_value0 (char *NAME)
1338 Return the value of the symbol named by the null-terminated string
1339 NAME in the current module. If the symbol named NAME is unbound in
1340 the current module, return SCM_UNDEFINED.
1341
1342** The new function scm_sysintern0 creates new top-level variables,
1343without assigning them a value.
1344
1345SCM scm_sysintern0 (char *NAME)
1346 Create a new Scheme top-level variable named NAME. NAME is a
1347 null-terminated string. Return the variable's value cell.
1348
1349** The function scm_internal_catch is the guts of catch. It handles
1350all the mechanics of setting up a catch target, invoking the catch
1351body, and perhaps invoking the handler if the body does a throw.
1352
1353The function is designed to be usable from C code, but is general
1354enough to implement all the semantics Guile Scheme expects from throw.
1355
1356TAG is the catch tag. Typically, this is a symbol, but this function
1357doesn't actually care about that.
1358
1359BODY is a pointer to a C function which runs the body of the catch;
1360this is the code you can throw from. We call it like this:
1361 BODY (BODY_DATA, JMPBUF)
1362where:
1363 BODY_DATA is just the BODY_DATA argument we received; we pass it
1364 through to BODY as its first argument. The caller can make
1365 BODY_DATA point to anything useful that BODY might need.
1366 JMPBUF is the Scheme jmpbuf object corresponding to this catch,
1367 which we have just created and initialized.
1368
1369HANDLER is a pointer to a C function to deal with a throw to TAG,
1370should one occur. We call it like this:
1371 HANDLER (HANDLER_DATA, THROWN_TAG, THROW_ARGS)
1372where
1373 HANDLER_DATA is the HANDLER_DATA argument we recevied; it's the
1374 same idea as BODY_DATA above.
1375 THROWN_TAG is the tag that the user threw to; usually this is
1376 TAG, but it could be something else if TAG was #t (i.e., a
1377 catch-all), or the user threw to a jmpbuf.
1378 THROW_ARGS is the list of arguments the user passed to the THROW
1379 function.
1380
1381BODY_DATA is just a pointer we pass through to BODY. HANDLER_DATA
1382is just a pointer we pass through to HANDLER. We don't actually
1383use either of those pointers otherwise ourselves. The idea is
1384that, if our caller wants to communicate something to BODY or
1385HANDLER, it can pass a pointer to it as MUMBLE_DATA, which BODY and
1386HANDLER can then use. Think of it as a way to make BODY and
1387HANDLER closures, not just functions; MUMBLE_DATA points to the
1388enclosed variables.
1389
1390Of course, it's up to the caller to make sure that any data a
1391MUMBLE_DATA needs is protected from GC. A common way to do this is
1392to make MUMBLE_DATA a pointer to data stored in an automatic
1393structure variable; since the collector must scan the stack for
1394references anyway, this assures that any references in MUMBLE_DATA
1395will be found.
1396
1397** The new function scm_internal_lazy_catch is exactly like
1398scm_internal_catch, except:
1399
1400- It does not unwind the stack (this is the major difference).
1401- If handler returns, its value is returned from the throw.
1402- BODY always receives #f as its JMPBUF argument (since there's no
1403 jmpbuf associated with a lazy catch, because we don't unwind the
1404 stack.)
1405
1406** scm_body_thunk is a new body function you can pass to
1407scm_internal_catch if you want the body to be like Scheme's `catch'
1408--- a thunk, or a function of one argument if the tag is #f.
1409
1410BODY_DATA is a pointer to a scm_body_thunk_data structure, which
1411contains the Scheme procedure to invoke as the body, and the tag
1412we're catching. If the tag is #f, then we pass JMPBUF (created by
1413scm_internal_catch) to the body procedure; otherwise, the body gets
1414no arguments.
1415
1416** scm_handle_by_proc is a new handler function you can pass to
1417scm_internal_catch if you want the handler to act like Scheme's catch
1418--- call a procedure with the tag and the throw arguments.
1419
1420If the user does a throw to this catch, this function runs a handler
1421procedure written in Scheme. HANDLER_DATA is a pointer to an SCM
1422variable holding the Scheme procedure object to invoke. It ought to
1423be a pointer to an automatic variable (i.e., one living on the stack),
1424or the procedure object should be otherwise protected from GC.
1425
1426** scm_handle_by_message is a new handler function to use with
1427`scm_internal_catch' if you want Guile to print a message and die.
1428It's useful for dealing with throws to uncaught keys at the top level.
1429
1430HANDLER_DATA, if non-zero, is assumed to be a char * pointing to a
1431message header to print; if zero, we use "guile" instead. That
1432text is followed by a colon, then the message described by ARGS.
1433
1434** The return type of scm_boot_guile is now void; the function does
1435not return a value, and indeed, never returns at all.
1436
f3b1485f
JB
1437** The new function scm_shell makes it easy for user applications to
1438process command-line arguments in a way that is compatible with the
1439stand-alone guile interpreter (which is in turn compatible with SCSH,
1440the Scheme shell).
1441
1442To use the scm_shell function, first initialize any guile modules
1443linked into your application, and then call scm_shell with the values
7ed46dc8 1444of ARGC and ARGV your `main' function received. scm_shell will add
f3b1485f
JB
1445any SCSH-style meta-arguments from the top of the script file to the
1446argument vector, and then process the command-line arguments. This
1447generally means loading a script file or starting up an interactive
1448command interpreter. For details, see "Changes to the stand-alone
1449interpreter" above.
1450
095936d2
JB
1451** The new functions scm_get_meta_args and scm_count_argv help you
1452implement the SCSH-style meta-argument, `\'.
1453
1454char **scm_get_meta_args (int ARGC, char **ARGV)
1455 If the second element of ARGV is a string consisting of a single
1456 backslash character (i.e. "\\" in Scheme notation), open the file
1457 named by the following argument, parse arguments from it, and return
1458 the spliced command line. The returned array is terminated by a
1459 null pointer.
1460
1461 For details of argument parsing, see above, under "guile now accepts
1462 command-line arguments compatible with SCSH..."
1463
1464int scm_count_argv (char **ARGV)
1465 Count the arguments in ARGV, assuming it is terminated by a null
1466 pointer.
1467
1468For an example of how these functions might be used, see the source
1469code for the function scm_shell in libguile/script.c.
1470
1471You will usually want to use scm_shell instead of calling this
1472function yourself.
1473
1474** The new function scm_compile_shell_switches turns an array of
1475command-line arguments into Scheme code to carry out the actions they
1476describe. Given ARGC and ARGV, it returns a Scheme expression to
1477evaluate, and calls scm_set_program_arguments to make any remaining
1478command-line arguments available to the Scheme code. For example,
1479given the following arguments:
1480
1481 -e main -s ekko a speckled gecko
1482
1483scm_set_program_arguments will return the following expression:
1484
1485 (begin (load "ekko") (main (command-line)) (quit))
1486
1487You will usually want to use scm_shell instead of calling this
1488function yourself.
1489
1490** The function scm_shell_usage prints a usage message appropriate for
1491an interpreter that uses scm_compile_shell_switches to handle its
1492command-line arguments.
1493
1494void scm_shell_usage (int FATAL, char *MESSAGE)
1495 Print a usage message to the standard error output. If MESSAGE is
1496 non-zero, write it before the usage message, followed by a newline.
1497 If FATAL is non-zero, exit the process, using FATAL as the
1498 termination status. (If you want to be compatible with Guile,
1499 always use 1 as the exit status when terminating due to command-line
1500 usage problems.)
1501
1502You will usually want to use scm_shell instead of calling this
1503function yourself.
48d224d7
JB
1504
1505** scm_eval_0str now returns SCM_UNSPECIFIED if the string contains no
095936d2
JB
1506expressions. It used to return SCM_EOL. Earth-shattering.
1507
1508** The macros for declaring scheme objects in C code have been
1509rearranged slightly. They are now:
1510
1511SCM_SYMBOL (C_NAME, SCHEME_NAME)
1512 Declare a static SCM variable named C_NAME, and initialize it to
1513 point to the Scheme symbol whose name is SCHEME_NAME. C_NAME should
1514 be a C identifier, and SCHEME_NAME should be a C string.
1515
1516SCM_GLOBAL_SYMBOL (C_NAME, SCHEME_NAME)
1517 Just like SCM_SYMBOL, but make C_NAME globally visible.
1518
1519SCM_VCELL (C_NAME, SCHEME_NAME)
1520 Create a global variable at the Scheme level named SCHEME_NAME.
1521 Declare a static SCM variable named C_NAME, and initialize it to
1522 point to the Scheme variable's value cell.
1523
1524SCM_GLOBAL_VCELL (C_NAME, SCHEME_NAME)
1525 Just like SCM_VCELL, but make C_NAME globally visible.
1526
1527The `guile-snarf' script writes initialization code for these macros
1528to its standard output, given C source code as input.
1529
1530The SCM_GLOBAL macro is gone.
1531
1532** The scm_read_line and scm_read_line_x functions have been replaced
1533by Scheme code based on the %read-delimited! procedure (known to C
1534code as scm_read_delimited_x). See its description above for more
1535information.
48d224d7 1536
095936d2
JB
1537** The function scm_sys_open has been renamed to scm_open. It now
1538returns a port instead of an FD object.
ea00ecba 1539
095936d2
JB
1540* The dynamic linking support has changed. For more information, see
1541libguile/DYNAMIC-LINKING.
ea00ecba 1542
f7b47737
JB
1543\f
1544Guile 1.0b3
3065a62a 1545
f3b1485f
JB
1546User-visible changes from Thursday, September 5, 1996 until Guile 1.0
1547(Sun 5 Jan 1997):
3065a62a 1548
4b521edb 1549* Changes to the 'guile' program:
3065a62a 1550
4b521edb
JB
1551** Guile now loads some new files when it starts up. Guile first
1552searches the load path for init.scm, and loads it if found. Then, if
1553Guile is not being used to execute a script, and the user's home
1554directory contains a file named `.guile', Guile loads that.
c6486f8a 1555
4b521edb 1556** You can now use Guile as a shell script interpreter.
3065a62a
JB
1557
1558To paraphrase the SCSH manual:
1559
1560 When Unix tries to execute an executable file whose first two
1561 characters are the `#!', it treats the file not as machine code to
1562 be directly executed by the native processor, but as source code
1563 to be executed by some interpreter. The interpreter to use is
1564 specified immediately after the #! sequence on the first line of
1565 the source file. The kernel reads in the name of the interpreter,
1566 and executes that instead. It passes the interpreter the source
1567 filename as its first argument, with the original arguments
1568 following. Consult the Unix man page for the `exec' system call
1569 for more information.
1570
1a1945be
JB
1571Now you can use Guile as an interpreter, using a mechanism which is a
1572compatible subset of that provided by SCSH.
1573
3065a62a
JB
1574Guile now recognizes a '-s' command line switch, whose argument is the
1575name of a file of Scheme code to load. It also treats the two
1576characters `#!' as the start of a comment, terminated by `!#'. Thus,
1577to make a file of Scheme code directly executable by Unix, insert the
1578following two lines at the top of the file:
1579
1580#!/usr/local/bin/guile -s
1581!#
1582
1583Guile treats the argument of the `-s' command-line switch as the name
1584of a file of Scheme code to load, and treats the sequence `#!' as the
1585start of a block comment, terminated by `!#'.
1586
1587For example, here's a version of 'echo' written in Scheme:
1588
1589#!/usr/local/bin/guile -s
1590!#
1591(let loop ((args (cdr (program-arguments))))
1592 (if (pair? args)
1593 (begin
1594 (display (car args))
1595 (if (pair? (cdr args))
1596 (display " "))
1597 (loop (cdr args)))))
1598(newline)
1599
1600Why does `#!' start a block comment terminated by `!#', instead of the
1601end of the line? That is the notation SCSH uses, and although we
1602don't yet support the other SCSH features that motivate that choice,
1603we would like to be backward-compatible with any existing Guile
3763761c
JB
1604scripts once we do. Furthermore, if the path to Guile on your system
1605is too long for your kernel, you can start the script with this
1606horrible hack:
1607
1608#!/bin/sh
1609exec /really/long/path/to/guile -s "$0" ${1+"$@"}
1610!#
3065a62a
JB
1611
1612Note that some very old Unix systems don't support the `#!' syntax.
1613
c6486f8a 1614
4b521edb 1615** You can now run Guile without installing it.
6685dc83
JB
1616
1617Previous versions of the interactive Guile interpreter (`guile')
1618couldn't start up unless Guile's Scheme library had been installed;
1619they used the value of the environment variable `SCHEME_LOAD_PATH'
1620later on in the startup process, but not to find the startup code
1621itself. Now Guile uses `SCHEME_LOAD_PATH' in all searches for Scheme
1622code.
1623
1624To run Guile without installing it, build it in the normal way, and
1625then set the environment variable `SCHEME_LOAD_PATH' to a
1626colon-separated list of directories, including the top-level directory
1627of the Guile sources. For example, if you unpacked Guile so that the
1628full filename of this NEWS file is /home/jimb/guile-1.0b3/NEWS, then
1629you might say
1630
1631 export SCHEME_LOAD_PATH=/home/jimb/my-scheme:/home/jimb/guile-1.0b3
1632
c6486f8a 1633
4b521edb
JB
1634** Guile's read-eval-print loop no longer prints #<unspecified>
1635results. If the user wants to see this, she can evaluate the
1636expression (assert-repl-print-unspecified #t), perhaps in her startup
48d224d7 1637file.
6685dc83 1638
4b521edb
JB
1639** Guile no longer shows backtraces by default when an error occurs;
1640however, it does display a message saying how to get one, and how to
1641request that they be displayed by default. After an error, evaluate
1642 (backtrace)
1643to see a backtrace, and
1644 (debug-enable 'backtrace)
1645to see them by default.
6685dc83 1646
6685dc83 1647
d9fb83d9 1648
4b521edb
JB
1649* Changes to Guile Scheme:
1650
1651** Guile now distinguishes between #f and the empty list.
1652
1653This is for compatibility with the IEEE standard, the (possibly)
1654upcoming Revised^5 Report on Scheme, and many extant Scheme
1655implementations.
1656
1657Guile used to have #f and '() denote the same object, to make Scheme's
1658type system more compatible with Emacs Lisp's. However, the change
1659caused too much trouble for Scheme programmers, and we found another
1660way to reconcile Emacs Lisp with Scheme that didn't require this.
1661
1662
1663** Guile's delq, delv, delete functions, and their destructive
c6486f8a
JB
1664counterparts, delq!, delv!, and delete!, now remove all matching
1665elements from the list, not just the first. This matches the behavior
1666of the corresponding Emacs Lisp functions, and (I believe) the Maclisp
1667functions which inspired them.
1668
1669I recognize that this change may break code in subtle ways, but it
1670seems best to make the change before the FSF's first Guile release,
1671rather than after.
1672
1673
4b521edb 1674** The compiled-library-path function has been deleted from libguile.
6685dc83 1675
4b521edb 1676** The facilities for loading Scheme source files have changed.
c6486f8a 1677
4b521edb 1678*** The variable %load-path now tells Guile which directories to search
6685dc83
JB
1679for Scheme code. Its value is a list of strings, each of which names
1680a directory.
1681
4b521edb
JB
1682*** The variable %load-extensions now tells Guile which extensions to
1683try appending to a filename when searching the load path. Its value
1684is a list of strings. Its default value is ("" ".scm").
1685
1686*** (%search-load-path FILENAME) searches the directories listed in the
1687value of the %load-path variable for a Scheme file named FILENAME,
1688with all the extensions listed in %load-extensions. If it finds a
1689match, then it returns its full filename. If FILENAME is absolute, it
1690returns it unchanged. Otherwise, it returns #f.
6685dc83 1691
4b521edb
JB
1692%search-load-path will not return matches that refer to directories.
1693
1694*** (primitive-load FILENAME :optional CASE-INSENSITIVE-P SHARP)
1695uses %seach-load-path to find a file named FILENAME, and loads it if
1696it finds it. If it can't read FILENAME for any reason, it throws an
1697error.
6685dc83
JB
1698
1699The arguments CASE-INSENSITIVE-P and SHARP are interpreted as by the
4b521edb
JB
1700`read' function.
1701
1702*** load uses the same searching semantics as primitive-load.
1703
1704*** The functions %try-load, try-load-with-path, %load, load-with-path,
1705basic-try-load-with-path, basic-load-with-path, try-load-module-with-
1706path, and load-module-with-path have been deleted. The functions
1707above should serve their purposes.
1708
1709*** If the value of the variable %load-hook is a procedure,
1710`primitive-load' applies its value to the name of the file being
1711loaded (without the load path directory name prepended). If its value
1712is #f, it is ignored. Otherwise, an error occurs.
1713
1714This is mostly useful for printing load notification messages.
1715
1716
1717** The function `eval!' is no longer accessible from the scheme level.
1718We can't allow operations which introduce glocs into the scheme level,
1719because Guile's type system can't handle these as data. Use `eval' or
1720`read-and-eval!' (see below) as replacement.
1721
1722** The new function read-and-eval! reads an expression from PORT,
1723evaluates it, and returns the result. This is more efficient than
1724simply calling `read' and `eval', since it is not necessary to make a
1725copy of the expression for the evaluator to munge.
1726
1727Its optional arguments CASE_INSENSITIVE_P and SHARP are interpreted as
1728for the `read' function.
1729
1730
1731** The function `int?' has been removed; its definition was identical
1732to that of `integer?'.
1733
1734** The functions `<?', `<?', `<=?', `=?', `>?', and `>=?'. Code should
1735use the R4RS names for these functions.
1736
1737** The function object-properties no longer returns the hash handle;
1738it simply returns the object's property list.
1739
1740** Many functions have been changed to throw errors, instead of
1741returning #f on failure. The point of providing exception handling in
1742the language is to simplify the logic of user code, but this is less
1743useful if Guile's primitives don't throw exceptions.
1744
1745** The function `fileno' has been renamed from `%fileno'.
1746
1747** The function primitive-mode->fdes returns #t or #f now, not 1 or 0.
1748
1749
1750* Changes to Guile's C interface:
1751
1752** The library's initialization procedure has been simplified.
1753scm_boot_guile now has the prototype:
1754
1755void scm_boot_guile (int ARGC,
1756 char **ARGV,
1757 void (*main_func) (),
1758 void *closure);
1759
1760scm_boot_guile calls MAIN_FUNC, passing it CLOSURE, ARGC, and ARGV.
1761MAIN_FUNC should do all the work of the program (initializing other
1762packages, reading user input, etc.) before returning. When MAIN_FUNC
1763returns, call exit (0); this function never returns. If you want some
1764other exit value, MAIN_FUNC may call exit itself.
1765
1766scm_boot_guile arranges for program-arguments to return the strings
1767given by ARGC and ARGV. If MAIN_FUNC modifies ARGC/ARGV, should call
1768scm_set_program_arguments with the final list, so Scheme code will
1769know which arguments have been processed.
1770
1771scm_boot_guile establishes a catch-all catch handler which prints an
1772error message and exits the process. This means that Guile exits in a
1773coherent way when system errors occur and the user isn't prepared to
1774handle it. If the user doesn't like this behavior, they can establish
1775their own universal catcher in MAIN_FUNC to shadow this one.
1776
1777Why must the caller do all the real work from MAIN_FUNC? The garbage
1778collector assumes that all local variables of type SCM will be above
1779scm_boot_guile's stack frame on the stack. If you try to manipulate
1780SCM values after this function returns, it's the luck of the draw
1781whether the GC will be able to find the objects you allocate. So,
1782scm_boot_guile function exits, rather than returning, to discourage
1783people from making that mistake.
1784
1785The IN, OUT, and ERR arguments were removed; there are other
1786convenient ways to override these when desired.
1787
1788The RESULT argument was deleted; this function should never return.
1789
1790The BOOT_CMD argument was deleted; the MAIN_FUNC argument is more
1791general.
1792
1793
1794** Guile's header files should no longer conflict with your system's
1795header files.
1796
1797In order to compile code which #included <libguile.h>, previous
1798versions of Guile required you to add a directory containing all the
1799Guile header files to your #include path. This was a problem, since
1800Guile's header files have names which conflict with many systems'
1801header files.
1802
1803Now only <libguile.h> need appear in your #include path; you must
1804refer to all Guile's other header files as <libguile/mumble.h>.
1805Guile's installation procedure puts libguile.h in $(includedir), and
1806the rest in $(includedir)/libguile.
1807
1808
1809** Two new C functions, scm_protect_object and scm_unprotect_object,
1810have been added to the Guile library.
1811
1812scm_protect_object (OBJ) protects OBJ from the garbage collector.
1813OBJ will not be freed, even if all other references are dropped,
1814until someone does scm_unprotect_object (OBJ). Both functions
1815return OBJ.
1816
1817Note that calls to scm_protect_object do not nest. You can call
1818scm_protect_object any number of times on a given object, and the
1819next call to scm_unprotect_object will unprotect it completely.
1820
1821Basically, scm_protect_object and scm_unprotect_object just
1822maintain a list of references to things. Since the GC knows about
1823this list, all objects it mentions stay alive. scm_protect_object
1824adds its argument to the list; scm_unprotect_object remove its
1825argument from the list.
1826
1827
1828** scm_eval_0str now returns the value of the last expression
1829evaluated.
1830
1831** The new function scm_read_0str reads an s-expression from a
1832null-terminated string, and returns it.
1833
1834** The new function `scm_stdio_to_port' converts a STDIO file pointer
1835to a Scheme port object.
1836
1837** The new function `scm_set_program_arguments' allows C code to set
1838the value teruturned by the Scheme `program-arguments' function.
6685dc83 1839
6685dc83 1840\f
1a1945be
JB
1841Older changes:
1842
1843* Guile no longer includes sophisticated Tcl/Tk support.
1844
1845The old Tcl/Tk support was unsatisfying to us, because it required the
1846user to link against the Tcl library, as well as Tk and Guile. The
1847interface was also un-lispy, in that it preserved Tcl/Tk's practice of
1848referring to widgets by names, rather than exporting widgets to Scheme
1849code as a special datatype.
1850
1851In the Usenix Tk Developer's Workshop held in July 1996, the Tcl/Tk
1852maintainers described some very interesting changes in progress to the
1853Tcl/Tk internals, which would facilitate clean interfaces between lone
1854Tk and other interpreters --- even for garbage-collected languages
1855like Scheme. They expected the new Tk to be publicly available in the
1856fall of 1996.
1857
1858Since it seems that Guile might soon have a new, cleaner interface to
1859lone Tk, and that the old Guile/Tk glue code would probably need to be
1860completely rewritten, we (Jim Blandy and Richard Stallman) have
1861decided not to support the old code. We'll spend the time instead on
1862a good interface to the newer Tk, as soon as it is available.
5c54da76 1863
8512dea6 1864Until then, gtcltk-lib provides trivial, low-maintenance functionality.
deb95d71 1865
5c54da76
JB
1866\f
1867Copyright information:
1868
ea00ecba 1869Copyright (C) 1996,1997 Free Software Foundation, Inc.
5c54da76
JB
1870
1871 Permission is granted to anyone to make or distribute verbatim copies
1872 of this document as received, in any medium, provided that the
1873 copyright notice and this permission notice are preserved,
1874 thus giving the recipient permission to redistribute in turn.
1875
1876 Permission is granted to distribute modified versions
1877 of this document, or of portions of it,
1878 under the above conditions, provided also that they
1879 carry prominent notices stating who last changed them.
1880
48d224d7
JB
1881\f
1882Local variables:
1883mode: outline
1884paragraph-separate: "[ \f]*$"
1885end:
1886