mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-01 20:30:28 +02:00
reading list. * gh.texi: Insert page break before chapter. Remove page breaks within the chapter. * Makefile.am: Add script-getopt.texi. * guile.texi (Top): Include and link to new script-getopt.texi chapter. * script-getopt.texi: New chapter on command line handling. (Written and contributed by Martin Grabmueller, revised by me.)
370 lines
12 KiB
Text
370 lines
12 KiB
Text
\input texinfo
|
|
@c -*-texinfo-*-
|
|
@c %**start of header
|
|
@setfilename guile.info
|
|
@settitle Guile Reference Manual
|
|
@c %**end of header
|
|
|
|
@c Neil's notes:
|
|
|
|
@c This file started life as a copy of guile-ref.texi, which I then
|
|
@c modified to reflect the organization described in
|
|
@c sources/jimb-org.texi.
|
|
|
|
@c Jim's notes:
|
|
|
|
@c Remember to use "subr" whereever appropriate.
|
|
@c Actually, use "primitive", not "subr." Why coin a new term?
|
|
@c FIXME: gotta change existing "subr" uses to "Primitive".
|
|
@c In my text for the Guile snarfer, I've used the term "subr" to denote
|
|
@c a C function made available to the Scheme world as a function. This
|
|
@c terminology is weird, but consistent with the function names and also
|
|
@c with Emacs Lisp, which I assume takes Maclisp's lead.
|
|
|
|
@c Tim's notes:
|
|
|
|
@c When adding a new function to the Guile manual, please document
|
|
@c it with @deffn as one of `primitive', `procedure', or `syntax'.
|
|
@c
|
|
@c The following Guile primitives are not documented. We have a lot
|
|
@c of work to do.
|
|
@c
|
|
@c arbiters.c: make-arbiter, try-arbiter, release-arbiter
|
|
@c async.c: async, async-mark, system-async, system-async-mark,
|
|
@c run-asyncs, noop, set-tick-rate, set-switch-rate,
|
|
@c unmask-signals, mask-signals
|
|
@c backtrace.c: backtrace, display-error, display-application,
|
|
@c display-backtrace
|
|
@c chars.c: char-is-both?
|
|
@c debug.c: single-step, memoized?, unmemoize, memoized-environment,
|
|
@c procedure-name, procedure-source, procedure-environment,
|
|
@c local-eval, debug-object?, debug-hang
|
|
@c dynl.c: c-registered-modules, c-clear-registered-modules,
|
|
@c dynamic-link, dynamic-object?, dynamic-unlink, dynamic-func,
|
|
@c dynamic-call, dynamic-args-call
|
|
@c eval.c: procedure->syntax, procedure->macro, procedure->memoizing-macro,
|
|
@c macro-name, macro-transformer
|
|
@c fluids.c: make-fluid, fluid?, fluid-ref, fluid-set, with-fluids*
|
|
@c gc.c: map-free-list, unhash-name
|
|
@c kw.c: make-keyword-from-dash-symbol
|
|
@c net_db.c: sethost, setnet, setproto, setserv
|
|
@c print.c: current-pstate
|
|
@c procs.c: make-cclo, closure?, thunk?
|
|
@c read.c: read-hash-extend
|
|
@c readline.c: readline, add-history
|
|
@c srcprop.c: source-properties, set-source-properties!,
|
|
@c source-property, set-source-property!
|
|
@c stacks.c: make-stack, stack-ref, stack-length,
|
|
@c frame?, last-stack-frame, frame-number, frame-source,
|
|
@c frame-procedure, frame-arguments, frame-previous, frame-next,
|
|
@c frame-real?, frame-procedure?, frame-evaluating-args?,
|
|
@c frame-overflow
|
|
@c struct.c: struct-vtable-tag
|
|
@c symbols.c: builtin-weak-bindings
|
|
@c tag.c: tag
|
|
@c threads.c: single-active-thread?, yield, call-with-new-thread,
|
|
@c make-condition-variable, wait-condition-variable,
|
|
@c signal-condition-variable
|
|
@c throw.c: lazy-catch, vector-set-length!
|
|
@c unif.c: uniform-vector-ref, uniform-array-set1!
|
|
@c variable.c: make-variable, make-undefined-variable, variable?,
|
|
@c variable-ref, variable-set!, builtin-variable, variable-bound?
|
|
@c weaks.c: make-weak-vector, weak-vector, list->weak-vector,
|
|
@c weak-vector? make-weak-key-hash-table,
|
|
@c make-weak-value-hash-table, make-doubly-weak-hash-table,
|
|
@c weak-key-hash-table?, weak-value-hash-table?,
|
|
@c doubly-weak-hash-table?
|
|
@c
|
|
@c If you have worked with some of these concepts, implemented them,
|
|
@c or just happen to know what they do, please write up a little
|
|
@c explanation -- it would be a big help. Alternatively, if you
|
|
@c know of a great reason why some of these should *not* go in the
|
|
@c manual, please let me know.
|
|
@c
|
|
@c The following functions are currently left undocumented for various reasons.
|
|
@c * should be documented in a section on debugging or Guile internals:
|
|
@c ports.c: pt-size, pt-member
|
|
@c eval.c: apply:nconc2last
|
|
@c * trivial underlying implementations of R4RS functions:
|
|
@c numbers.c: $asinh, $acosh, $atanh, $sqrt, $abs, $exp, $log, $sin,
|
|
@c $cos, $tan, $asin, $acos, $atan, $sinh, $cosh, $tanh, $expt,
|
|
@c $atan2
|
|
@c
|
|
@c Thanks. -twp
|
|
|
|
@c Define indices that are used in the Guile Scheme part of the
|
|
@c reference manual to group stuff according to whether it is R5RS or a
|
|
@c Guile extension.
|
|
@defcodeindex r5
|
|
@defcodeindex ge
|
|
|
|
@include version.texi
|
|
|
|
@c @iftex
|
|
@c @cropmarks
|
|
@c @end iftex
|
|
|
|
@dircategory The Algorithmic Language Scheme
|
|
@direntry
|
|
* Guile Reference: (guile). The Guile reference manual.
|
|
@end direntry
|
|
|
|
@setchapternewpage off
|
|
|
|
@ifinfo
|
|
Guile Reference Manual
|
|
Copyright (C) 1996 Free Software Foundation @*
|
|
Copyright (C) 1997 Free Software Foundation @*
|
|
Copyright (C) 2000 Free Software Foundation @*
|
|
Copyright (C) 2001 Free Software Foundation
|
|
|
|
Permission is granted to make and distribute verbatim copies of
|
|
this manual provided the copyright notice and this permission notice
|
|
are preserved on all copies.
|
|
|
|
@ignore
|
|
Permission is granted to process this file through TeX and print the
|
|
results, provided the printed document carries copying permission
|
|
notice identical to this one except for the removal of this paragraph
|
|
(this paragraph not being relevant to the printed manual).
|
|
@end ignore
|
|
|
|
Permission is granted to copy and distribute modified versions of this
|
|
manual under the conditions for verbatim copying, provided that the entire
|
|
resulting derived work is distributed under the terms of a permission
|
|
notice identical to this one.
|
|
|
|
Permission is granted to copy and distribute translations of this manual
|
|
into another language, under the above conditions for modified versions,
|
|
except that this permission notice may be stated in a translation approved
|
|
by the Free Software Foundation.
|
|
@end ifinfo
|
|
|
|
@titlepage
|
|
@sp 10
|
|
@comment The title is printed in a large font.
|
|
@title Guile Reference Manual
|
|
@subtitle $Id: guile.texi,v 1.2 2001-03-30 22:16:20 ossau Exp $
|
|
@subtitle For use with Guile @value{VERSION}
|
|
@author Mark Galassi
|
|
@author Cygnus Solution and Los Alamos National Laboratory
|
|
@author @email{rosalia@@cygnus.com}
|
|
@author
|
|
@author Jim Blandy
|
|
@author Free Software Foundation and MIT AI Lab
|
|
@author @email{jimb@@red-bean.com}
|
|
@author
|
|
@author Gary Houston
|
|
@author @email{ghouston@@actrix.gen.nz}
|
|
@author
|
|
@author Tim Pierce
|
|
@author @email{twp@@skepsis.com}
|
|
@author
|
|
@author Neil Jerram
|
|
@author @email{neil@@ossau.uklinux.net}
|
|
@c The following two commands start the copyright page.
|
|
@page
|
|
@vskip 0pt plus 1filll
|
|
@vskip 0pt plus 1filll
|
|
Copyright @copyright{} 1996 Free Software Foundation
|
|
|
|
Copyright @copyright{} 1997 Free Software Foundation
|
|
|
|
Copyright @copyright{} 2000 Free Software Foundation
|
|
|
|
Permission is granted to make and distribute verbatim copies of
|
|
this manual provided the copyright notice and this permission notice
|
|
are preserved on all copies.
|
|
|
|
Permission is granted to copy and distribute modified versions of this
|
|
manual under the conditions for verbatim copying, provided that the entire
|
|
resulting derived work is distributed under the terms of a permission
|
|
notice identical to this one.
|
|
|
|
Permission is granted to copy and distribute translations of this manual
|
|
into another language, under the above conditions for modified versions,
|
|
except that this permission notice may be stated in a translation approved
|
|
by Free Software Foundation.
|
|
@end titlepage
|
|
|
|
@c @smallbook
|
|
@finalout
|
|
@headings double
|
|
|
|
@c Where to find Guile examples.
|
|
@set example-dir doc/examples
|
|
|
|
@ifinfo
|
|
@node Top, Guile License, (dir), (dir)
|
|
@top The Guile Reference Manual
|
|
|
|
This reference manual documents Guile, GNU's Ubiquitous Intelligent
|
|
Language for Extensions. It describes how to use Guile in many useful
|
|
and interesting ways.
|
|
|
|
This Info file contains edition 1.0 of the reference manual,
|
|
corresponding to Guile version @value{VERSION}.
|
|
@end ifinfo
|
|
|
|
@menu
|
|
Preface
|
|
|
|
* Guile License:: Conditions for copying and using Guile.
|
|
* Manual Layout:: How to read the rest of this manual.
|
|
|
|
Part I: Introduction to Guile
|
|
|
|
* What is Guile?:: And what does it do?
|
|
* Whirlwind Tour:: An introductory whirlwind tour.
|
|
* Reporting Bugs:: Reporting bugs in Guile or this manual.
|
|
|
|
Part II: Guile Scheme
|
|
|
|
* Scheme Intro:: Introduction to Guile Scheme.
|
|
* Basic Ideas:: Basic ideas in Scheme.
|
|
* Data Types:: Data types for generic use.
|
|
* Procedures and Macros:: Procedures and macros.
|
|
* Utility Functions:: General utility functions.
|
|
* Binding Constructs:: Definitions and variable bindings.
|
|
* Control Mechanisms:: Controlling the flow of program execution.
|
|
* Input and Output:: Ports, reading and writing.
|
|
* Read/Load/Eval:: Reading and evaluating Scheme code.
|
|
* Memory Management:: Memory management and garbage collection.
|
|
* Objects:: Low level object orientation support.
|
|
* Modules:: Designing reusable code libraries.
|
|
* Scheduling:: Threads, mutexes, asyncs and dynamic roots.
|
|
* Options and Config:: Runtime options and configuration.
|
|
* Translation:: Support for translating other languages.
|
|
* Debugging:: Internal debugging interface.
|
|
* Deprecated:: Features that are planned to disappear.
|
|
* Further Reading:: Where to find out more about Scheme programming.
|
|
* R5RS Index::
|
|
* Guile Extensions Index::
|
|
|
|
Part III: Guile Modules
|
|
|
|
* SLIB:: Using the SLIB Scheme library.
|
|
* POSIX:: POSIX system calls and networking.
|
|
* Expect:: Controlling interactive programs with Guile.
|
|
* The Scheme shell (scsh)::
|
|
The SCSH compatibility module has been made an
|
|
add-on, so maybe it shouldn't be documented here
|
|
(though it is nice to have a link from here to the
|
|
Guile-scsh manual, if one exists).
|
|
* Tcl/Tk Interface::
|
|
|
|
Part IV: Guile Scripting
|
|
|
|
* Guile Scripting:: How to write Guile scripts.
|
|
* Command Line Handling:: Command line options and arguments.
|
|
|
|
Part V: Extending Applications Using Guile
|
|
|
|
* Libguile Intro:: Using Guile as an extension language.
|
|
* GH:: GH: a portable C to Scheme interface.
|
|
* Data Representation:: Data representation in Guile.
|
|
* Scheme Primitives:: Writing Scheme primitives in C.
|
|
* I/O Extensions:: Using and extending ports in C.
|
|
* Handling Errors:: How to handle errors in C code.
|
|
|
|
Appendices
|
|
|
|
* Obtaining and Installing Guile::
|
|
* Debugger User Interface::
|
|
|
|
Indices
|
|
|
|
* Concept Index::
|
|
* Procedure Index::
|
|
* Variable Index::
|
|
* Type Index::
|
|
|
|
@end menu
|
|
|
|
@include preface.texi
|
|
|
|
@c preliminary
|
|
@iftex
|
|
@page
|
|
@unnumbered{Part I: Introduction to Guile}
|
|
@end iftex
|
|
|
|
@include intro.texi
|
|
|
|
@c programming in Scheme
|
|
@iftex
|
|
@page
|
|
@unnumbered{Part II: Guile Scheme}
|
|
@end iftex
|
|
|
|
@include scheme-intro.texi
|
|
@include scheme-ideas.texi
|
|
@include scheme-data.texi
|
|
@include scheme-procedures.texi
|
|
@include scheme-utility.texi
|
|
@include scheme-binding.texi
|
|
@include scheme-control.texi
|
|
@include scheme-io.texi
|
|
@include scheme-evaluation.texi
|
|
@include scheme-memory.texi
|
|
@include scheme-modules.texi
|
|
@include scheme-scheduling.texi
|
|
@c object orientation support here
|
|
@include scheme-options.texi
|
|
@include scheme-translation.texi
|
|
@include scheme-debug.texi
|
|
@include deprecated.texi
|
|
@include scheme-reading.texi
|
|
@include scheme-indices.texi
|
|
|
|
@c Unix system interface
|
|
@iftex
|
|
@page
|
|
@unnumbered{Part III: Guile Modules}
|
|
@end iftex
|
|
|
|
@include slib.texi
|
|
@include posix.texi
|
|
@include expect.texi
|
|
@include scsh.texi
|
|
@include tcltk.texi
|
|
|
|
@c Guile as an scripting language
|
|
@iftex
|
|
@page
|
|
@unnumbered{Part IV: Guile Scripting}
|
|
@end iftex
|
|
|
|
@include scripts.texi
|
|
@include script-getopt.texi
|
|
|
|
@c Guile as an extension language
|
|
@iftex
|
|
@page
|
|
@unnumbered{Part V: Extending Applications Using Guile}
|
|
@end iftex
|
|
|
|
@include extend.texi
|
|
@include gh.texi
|
|
@include data-rep.texi
|
|
@include scm.texi
|
|
|
|
@c Appendices
|
|
@iftex
|
|
@page
|
|
@unnumbered{Appendices}
|
|
@end iftex
|
|
|
|
@include appendices.texi
|
|
|
|
@c Indices
|
|
@iftex
|
|
@page
|
|
@unnumbered{Indices}
|
|
@end iftex
|
|
|
|
@include indices.texi
|
|
|
|
@contents
|
|
|
|
@bye
|