mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-10 14:00:21 +02:00
* Remove obsolete `@c docstring' comments.
This commit is contained in:
parent
5c4b24e10f
commit
5411d88250
16 changed files with 10 additions and 667 deletions
|
@ -1,3 +1,13 @@
|
|||
2001-04-09 Neil Jerram <neil@ossau.uklinux.net>
|
||||
|
||||
* deprecated.texi, posix.texi, scheme-binding.texi,
|
||||
scheme-control.texi, scheme-data.texi, scheme-debug.texi,
|
||||
scheme-evaluation.texi, scheme-io.texi, scheme-memory.texi,
|
||||
scheme-modules.texi, scheme-options.texi, scheme-procedures.texi,
|
||||
scheme-scheduling.texi, scheme-translation.texi,
|
||||
scheme-utility.texi: Remove `@c docstring' comments, since they
|
||||
aren't used any more by the docstring tracking utilities.
|
||||
|
||||
2001-04-09 Martin Grabmueller <mgrabmue@cs.tu-berlin.de>
|
||||
|
||||
* scheme-data.texi (Pairs): New data type and procedure
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
@node Deprecated
|
||||
@chapter Deprecated
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "tag")
|
||||
@deffn primitive tag x
|
||||
Return an integer corresponding to the type of X. Deprecated.
|
||||
@end deffn
|
||||
|
|
141
doc/posix.texi
141
doc/posix.texi
|
@ -150,18 +150,15 @@ one, so that dropping references to one of these ports will not result
|
|||
in its garbage collection: it could be retrieved with fdopen or
|
||||
fdes->ports.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-revealed")
|
||||
@deffn primitive port-revealed port
|
||||
Return the revealed count for @var{port}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-port-revealed!")
|
||||
@deffn primitive set-port-revealed! port rcount
|
||||
Sets the revealed count for a port to a given value.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fileno")
|
||||
@deffn primitive fileno port
|
||||
Return the integer file descriptor underlying @var{port}. Does
|
||||
not change its revealed count.
|
||||
|
@ -172,7 +169,6 @@ Returns the integer file descriptor underlying @var{port}. As a
|
|||
side effect the revealed count of @var{port} is incremented.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fdopen")
|
||||
@deffn primitive fdopen fdes modes
|
||||
Return a new port based on the file descriptor @var{fdes}.
|
||||
Modes are given by the string @var{modes}. The revealed count
|
||||
|
@ -180,7 +176,6 @@ of the port is initialized to zero. The modes string is the
|
|||
same as that accepted by @ref{File Ports, open-file}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fdes->ports")
|
||||
@deffn primitive fdes->ports fd
|
||||
Return a list of existing ports which have @var{fdes} as an
|
||||
underlying file descriptor, without changing their revealed
|
||||
|
@ -199,7 +194,6 @@ descriptor, if one exists, and increments its revealed count.
|
|||
Otherwise, returns a new output port with a revealed count of 1.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-move->fdes")
|
||||
@deffn primitive primitive-move->fdes port fd
|
||||
Moves the underlying file descriptor for @var{port} to the integer
|
||||
value @var{fdes} without changing the revealed count of @var{port}.
|
||||
|
@ -221,7 +215,6 @@ The return value is unspecified.
|
|||
Decrements the revealed count for a port.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fsync")
|
||||
@deffn primitive fsync object
|
||||
Copies any unwritten data for the specified output file descriptor to disk.
|
||||
If @var{port/fd} is a port, its buffer is flushed before the underlying
|
||||
|
@ -229,7 +222,6 @@ file descriptor is fsync'd.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "open")
|
||||
@deffn primitive open path flags [mode]
|
||||
Open the file named by @var{path} for reading and/or writing.
|
||||
@var{flags} is an integer specifying how the file should be opened.
|
||||
|
@ -260,13 +252,11 @@ See the Unix documentation of the @code{open} system call
|
|||
for additional flags.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "open-fdes")
|
||||
@deffn primitive open-fdes path flags [mode]
|
||||
Similar to @code{open} but return a file descriptor instead of
|
||||
a port.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "close")
|
||||
@deffn primitive close fd_or_port
|
||||
Similar to close-port (@pxref{Closing, close-port}), but also works on
|
||||
file descriptors. A side effect of closing a file descriptor is that
|
||||
|
@ -274,7 +264,6 @@ any ports using that file descriptor are moved to a different file
|
|||
descriptor and have their revealed counts set to zero.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "close-fdes")
|
||||
@deffn primitive close-fdes fd
|
||||
A simple wrapper for the @code{close} system call.
|
||||
Close file descriptor @var{fd}, which must be an integer.
|
||||
|
@ -283,7 +272,6 @@ the file descriptor will be closed even if a port is using it.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unread-char")
|
||||
@deffn primitive unread-char char [port]
|
||||
Place @var{char} in @var{port} so that it will be read by the
|
||||
next read operation. If called multiple times, the unread characters
|
||||
|
@ -291,7 +279,6 @@ will be read again in last-in first-out order. If @var{port} is
|
|||
not supplied, the current input port is used.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unread-string")
|
||||
@deffn primitive unread-string str port
|
||||
Place the string @var{str} in @var{port} so that its characters will be
|
||||
read in subsequent read operations. If called multiple times, the
|
||||
|
@ -299,7 +286,6 @@ unread characters will be read again in last-in first-out order. If
|
|||
@var{port} is not supplied, the current-input-port is used.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "pipe")
|
||||
@deffn primitive pipe
|
||||
Return a newly created pipe: a pair of ports which are linked
|
||||
together on the local machine. The @emph{car} is the input
|
||||
|
@ -325,7 +311,6 @@ All procedures also have the side effect when performing @code{dup2} that any
|
|||
ports using @var{newfd} are moved to a different file descriptor and have
|
||||
their revealed counts set to zero.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dup->fdes")
|
||||
@deffn primitive dup->fdes fd_or_port [fd]
|
||||
Return a new integer file descriptor referring to the open file
|
||||
designated by @var{fd_or_port}, which must be either an open
|
||||
|
@ -364,7 +349,6 @@ port.
|
|||
This procedure is equivalent to @code{(dup->port @var{port} @var{modes})}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "redirect-port")
|
||||
@deffn primitive redirect-port old new
|
||||
This procedure takes two ports and duplicates the underlying file
|
||||
descriptor from @var{old-port} into @var{new-port}. The
|
||||
|
@ -381,7 +365,6 @@ This procedure does not have any side effects on other ports or
|
|||
revealed counts.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dup2")
|
||||
@deffn primitive dup2 oldfd newfd
|
||||
A simple wrapper for the @code{dup2} system call.
|
||||
Copies the file descriptor @var{oldfd} to descriptor
|
||||
|
@ -393,7 +376,6 @@ is made to move away ports which are using @var{newfd}.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-mode")
|
||||
@deffn primitive port-mode port
|
||||
Return the port modes associated with the open port @var{port}.
|
||||
These will not necessarily be identical to the modes used when
|
||||
|
@ -401,7 +383,6 @@ the port was opened, since modes such as "append" which are
|
|||
used only during port creation are not retained.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "close-all-ports-except")
|
||||
@deffn primitive close-all-ports-except . ports
|
||||
[DEPRECATED] Close all open file ports used by the interpreter
|
||||
except for those supplied as arguments. This procedure
|
||||
|
@ -411,7 +392,6 @@ undesirable side-effect of flushing buffes, so it's deprecated.
|
|||
Use port-for-each instead.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-for-each")
|
||||
@deffn primitive port-for-each proc
|
||||
Apply @var{proc} to each port in the Guile port table
|
||||
in turn. The return value is unspecified. More specifically,
|
||||
|
@ -421,7 +401,6 @@ Changes to the port table while @var{port-for-each} is running
|
|||
have no effect as far as @var{port-for-each} is concerned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setvbuf")
|
||||
@deffn primitive setvbuf port mode [size]
|
||||
Set the buffering mode for @var{port}. @var{mode} can be:
|
||||
@table @code
|
||||
|
@ -435,7 +414,6 @@ If @var{size} is omitted, a default size will be used.
|
|||
@end table
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fcntl")
|
||||
@deffn primitive fcntl object cmd [value]
|
||||
Apply @var{command} to the specified file descriptor or the underlying
|
||||
file descriptor of the specified port. @var{value} is an optional
|
||||
|
@ -464,7 +442,6 @@ The value used to indicate the "close on exec" flag with @code{F_GETFL} or
|
|||
@end table
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "select")
|
||||
@deffn primitive select reads writes excepts [secs [usecs]]
|
||||
This procedure has a variety of uses: waiting for the ability
|
||||
to provide input, accept output, or the existance of
|
||||
|
@ -506,7 +483,6 @@ permissions, sizes and types of files); deleting, copying, renaming and
|
|||
linking files; creating and removing directories and querying their
|
||||
contents; syncing the file system and creating special files.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "access?")
|
||||
@deffn primitive access? path how
|
||||
Return @code{#t} if @var{path} corresponds to an existing file
|
||||
and the current process has the type of access specified by
|
||||
|
@ -532,7 +508,6 @@ test for existence of the file.
|
|||
@end deffn
|
||||
|
||||
@findex fstat
|
||||
@c docstring begin (texi-doc-string "guile" "stat")
|
||||
@deffn primitive stat object
|
||||
Return an object containing various information about the file
|
||||
determined by @var{obj}. @var{obj} can be a string containing
|
||||
|
@ -588,14 +563,12 @@ An integer representing the access permission bits.
|
|||
@end table
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "lstat")
|
||||
@deffn primitive lstat str
|
||||
Similar to @code{stat}, but does not follow symbolic links, i.e.,
|
||||
it will return information about a symbolic link itself, not the
|
||||
file it points to. @var{path} must be a string.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "readlink")
|
||||
@deffn primitive readlink path
|
||||
Return the value of the symbolic link named by @var{path} (a
|
||||
string), i.e., the file that the link points to.
|
||||
|
@ -603,7 +576,6 @@ string), i.e., the file that the link points to.
|
|||
|
||||
@findex fchown
|
||||
@findex lchown
|
||||
@c docstring begin (texi-doc-string "guile" "chown")
|
||||
@deffn primitive chown object owner group
|
||||
Change the ownership and group of the file referred to by @var{object} to
|
||||
the integer values @var{owner} and @var{group}. @var{object} can be
|
||||
|
@ -620,7 +592,6 @@ as @code{-1}, then that ID is not changed.
|
|||
@end deffn
|
||||
|
||||
@findex fchmod
|
||||
@c docstring begin (texi-doc-string "guile" "chmod")
|
||||
@deffn primitive chmod object mode
|
||||
Changes the permissions of the file referred to by @var{obj}.
|
||||
@var{obj} can be a string containing a file name or a port or integer file
|
||||
|
@ -631,7 +602,6 @@ the new permissions as a decimal number, e.g., @code{(chmod "foo" #o755)}.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "utime")
|
||||
@deffn primitive utime pathname [actime [modtime]]
|
||||
@code{utime} sets the access and modification times for the
|
||||
file named by @var{path}. If @var{actime} or @var{modtime} is
|
||||
|
@ -646,25 +616,21 @@ modification time to the current time.
|
|||
@end deffn
|
||||
|
||||
@findex unlink
|
||||
@c docstring begin (texi-doc-string "guile" "delete-file")
|
||||
@deffn primitive delete-file str
|
||||
Deletes (or "unlinks") the file specified by @var{path}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "copy-file")
|
||||
@deffn primitive copy-file oldfile newfile
|
||||
Copy the file specified by @var{path-from} to @var{path-to}.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@findex rename
|
||||
@c docstring begin (texi-doc-string "guile" "rename-file")
|
||||
@deffn primitive rename-file oldname newname
|
||||
Renames the file specified by @var{oldname} to @var{newname}.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "link")
|
||||
@deffn primitive link oldpath newpath
|
||||
Creates a new name @var{newpath} in the file system for the
|
||||
file named by @var{oldpath}. If @var{oldpath} is a symbolic
|
||||
|
@ -672,13 +638,11 @@ link, the link may or may not be followed depending on the
|
|||
system.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "symlink")
|
||||
@deffn primitive symlink oldpath newpath
|
||||
Create a symbolic link named @var{path-to} with the value (i.e., pointing to)
|
||||
@var{path-from}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "mkdir")
|
||||
@deffn primitive mkdir path [mode]
|
||||
Create a new directory named by @var{path}. If @var{mode} is omitted
|
||||
then the permissions of the directory file are set using the current
|
||||
|
@ -686,50 +650,42 @@ umask. Otherwise they are set to the decimal value specified with
|
|||
@var{mode}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "rmdir")
|
||||
@deffn primitive rmdir path
|
||||
Remove the existing directory named by @var{path}. The directory must
|
||||
be empty for this to succeed. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "opendir")
|
||||
@deffn primitive opendir dirname
|
||||
Open the directory specified by @var{path} and return a directory
|
||||
stream.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "directory-stream?")
|
||||
@deffn primitive directory-stream? obj
|
||||
Return a boolean indicating whether @var{object} is a directory
|
||||
stream as returned by @code{opendir}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "readdir")
|
||||
@deffn primitive readdir port
|
||||
Return (as a string) the next directory entry from the directory stream
|
||||
@var{stream}. If there is no remaining entry to be read then the
|
||||
end of file object is returned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "rewinddir")
|
||||
@deffn primitive rewinddir port
|
||||
Reset the directory port @var{stream} so that the next call to
|
||||
@code{readdir} will return the first directory entry.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "closedir")
|
||||
@deffn primitive closedir port
|
||||
Close the directory stream @var{stream}.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sync")
|
||||
@deffn primitive sync
|
||||
Flush the operating system disk buffers.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "mknod")
|
||||
@deffn primitive mknod path type perms dev
|
||||
Creates a new special file, such as a file corresponding to a device.
|
||||
@var{path} specifies the name of the file. @var{type} should
|
||||
|
@ -748,7 +704,6 @@ E.g.,
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "tmpnam")
|
||||
@deffn primitive tmpnam
|
||||
Return a name in the file system that does not match any
|
||||
existing file. However there is no guarantee that another
|
||||
|
@ -757,14 +712,12 @@ Care should be taken if opening the file, e.g., use the
|
|||
@code{O_EXCL} open flag or use @code{mkstemp!} instead.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dirname")
|
||||
@deffn primitive dirname filename
|
||||
Return the directory name component of the file name
|
||||
@var{filename}. If @var{filename} does not contain a directory
|
||||
component, @code{.} is returned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "basename")
|
||||
@deffn primitive basename filename [suffix]
|
||||
Return the base name of the file name @var{filename}. The
|
||||
base name is the file name without any directory components.
|
||||
|
@ -823,14 +776,12 @@ Return the next entry in the user database, using the stream set by
|
|||
Closes the stream used by @code{getpwent}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setpw")
|
||||
@deffn primitive setpw [arg]
|
||||
If called with a true argument, initialize or reset the password data
|
||||
stream. Otherwise, close the stream. The @code{setpwent} and
|
||||
@code{endpwent} procedures are implemented on top of this.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getpw")
|
||||
@deffn primitive getpw [user]
|
||||
Look up an entry in the user database. @var{obj} can be an integer,
|
||||
a string, or omitted, giving the behaviour of getpwuid, getpwnam
|
||||
|
@ -875,14 +826,12 @@ Closes the stream used by @code{getgrent}.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setgr")
|
||||
@deffn primitive setgr [arg]
|
||||
If called with a true argument, initialize or reset the group data
|
||||
stream. Otherwise, close the stream. The @code{setgrent} and
|
||||
@code{endgrent} procedures are implemented on top of this.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getgr")
|
||||
@deffn primitive getgr [name]
|
||||
Look up an entry in the group database. @var{obj} can be an integer,
|
||||
a string, or omitted, giving the behaviour of getgrgid, getgrnam
|
||||
|
@ -892,13 +841,11 @@ or getgrent respectively.
|
|||
@node Time
|
||||
@section Time
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "current-time")
|
||||
@deffn primitive current-time
|
||||
Return the number of seconds since 1970-01-01 00:00:00 UTC,
|
||||
excluding leap seconds.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "gettimeofday")
|
||||
@deffn primitive gettimeofday
|
||||
Return a pair containing the number of seconds and microseconds
|
||||
since 1970-01-01 00:00:00 UTC, excluding leap seconds. Note:
|
||||
|
@ -937,7 +884,6 @@ Time zone offset in seconds west of UTC (-46800 to 43200).
|
|||
Time zone label (a string), not necessarily unique.
|
||||
@end table
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "localtime")
|
||||
@deffn primitive localtime time [zone]
|
||||
Return an object representing the broken down components of
|
||||
@var{time}, an integer like the one returned by
|
||||
|
@ -946,14 +892,12 @@ optionally specified by @var{zone} (a string), otherwise the
|
|||
@code{TZ} environment variable or the system default is used.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "gmtime")
|
||||
@deffn primitive gmtime time
|
||||
Return an object representing the broken down components of
|
||||
@var{time}, an integer like the one returned by
|
||||
@code{current-time}. The values are calculated for UTC.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "mktime")
|
||||
@deffn primitive mktime sbd_time [zone]
|
||||
@var{bd-time} is an object representing broken down time and @code{zone}
|
||||
is an optional time zone specifier (otherwise the TZ environment variable
|
||||
|
@ -965,7 +909,6 @@ by @code{current-time}; the cdr is a broken down time object, similar to
|
|||
as @var{bd-time} but with normalized values.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "tzset")
|
||||
@deffn primitive tzset
|
||||
Initialize the timezone from the TZ environment variable
|
||||
or the system default. It's not usually necessary to call this procedure
|
||||
|
@ -973,7 +916,6 @@ since it's done automatically by other procedures that depend on the
|
|||
timezone.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "strftime")
|
||||
@deffn primitive strftime format stime
|
||||
Formats a time specification @var{time} using @var{template}. @var{time}
|
||||
is an object with time components in the form returned by @code{localtime}
|
||||
|
@ -984,7 +926,6 @@ is the formatted string.
|
|||
@xref{Formatting Date and Time, , , libc, The GNU C Library Reference Manual}.)
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "strptime")
|
||||
@deffn primitive strptime format string
|
||||
Performs the reverse action to @code{strftime}, parsing
|
||||
@var{string} according to the specification supplied in
|
||||
|
@ -1003,7 +944,6 @@ The value of this variable is the number of time units per second
|
|||
reported by the following procedures.
|
||||
@end defvar
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "times")
|
||||
@deffn primitive times
|
||||
Return an object with information about real and processor
|
||||
time. The following procedures accept such an object as an
|
||||
|
@ -1027,13 +967,11 @@ terminated child processes.
|
|||
@end table
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "get-internal-real-time")
|
||||
@deffn primitive get-internal-real-time
|
||||
Return the number of time units since the interpreter was
|
||||
started.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "get-internal-run-time")
|
||||
@deffn primitive get-internal-run-time
|
||||
Return the number of time units of processor time used by the
|
||||
interpreter. Both @emph{system} and @emph{user} time are
|
||||
|
@ -1043,7 +981,6 @@ included but subprocesses are not.
|
|||
@node Runtime Environment
|
||||
@section Runtime Environment
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "program-arguments")
|
||||
@deffn primitive program-arguments
|
||||
@deffnx procedure command-line
|
||||
Return the list of command line arguments passed to Guile, as a list of
|
||||
|
@ -1052,7 +989,6 @@ strings. The list includes the invoked program name, which is usually
|
|||
options like @code{-e} and @code{-l}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getenv")
|
||||
@deffn primitive getenv nam
|
||||
Looks up the string @var{name} in the current environment. The return
|
||||
value is @code{#f} unless a string of the form @code{NAME=VALUE} is
|
||||
|
@ -1072,7 +1008,6 @@ to the environment, replacing any existing string with name matching
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "environ")
|
||||
@deffn primitive environ [env]
|
||||
If @var{env} is omitted, return the current environment (in the
|
||||
Unix sense) as a list of strings. Otherwise set the current
|
||||
|
@ -1083,7 +1018,6 @@ processes, to the supplied list of strings. Each member of
|
|||
then the return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "putenv")
|
||||
@deffn primitive putenv str
|
||||
Modifies the environment of the current process, which is
|
||||
also the default environment inherited by child processes.
|
||||
|
@ -1103,19 +1037,16 @@ The return value is unspecified.
|
|||
@section Processes
|
||||
|
||||
@findex cd
|
||||
@c docstring begin (texi-doc-string "guile" "chdir")
|
||||
@deffn primitive chdir str
|
||||
Change the current working directory to @var{path}.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@findex pwd
|
||||
@c docstring begin (texi-doc-string "guile" "getcwd")
|
||||
@deffn primitive getcwd
|
||||
Return the name of the current working directory.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "umask")
|
||||
@deffn primitive umask [mode]
|
||||
If @var{mode} is omitted, retuns a decimal number representing the current
|
||||
file creation mask. Otherwise the file creation mask is set to
|
||||
|
@ -1124,34 +1055,28 @@ file creation mask. Otherwise the file creation mask is set to
|
|||
E.g., @code{(umask #o022)} sets the mask to octal 22, decimal 18.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getpid")
|
||||
@deffn primitive getpid
|
||||
Return an integer representing the current process ID.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getgroups")
|
||||
@deffn primitive getgroups
|
||||
Return a vector of integers representing the current
|
||||
supplimentary group IDs.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getppid")
|
||||
@deffn primitive getppid
|
||||
Return an integer representing the process ID of the parent
|
||||
process.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getuid")
|
||||
@deffn primitive getuid
|
||||
Return an integer representing the current real user ID.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getgid")
|
||||
@deffn primitive getgid
|
||||
Return an integer representing the current real group ID.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "geteuid")
|
||||
@deffn primitive geteuid
|
||||
Return an integer representing the current effective user ID.
|
||||
If the system does not support effective IDs, then the real ID
|
||||
|
@ -1159,7 +1084,6 @@ is returned. @code{(feature? 'EIDs)} reports whether the
|
|||
system supports effective IDs.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getegid")
|
||||
@deffn primitive getegid
|
||||
Return an integer representing the current effective group ID.
|
||||
If the system does not support effective IDs, then the real ID
|
||||
|
@ -1167,21 +1091,18 @@ is returned. @code{(feature? 'EIDs)} reports whether the
|
|||
system supports effective IDs.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setuid")
|
||||
@deffn primitive setuid id
|
||||
Sets both the real and effective user IDs to the integer @var{id}, provided
|
||||
the process has appropriate privileges.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setgid")
|
||||
@deffn primitive setgid id
|
||||
Sets both the real and effective group IDs to the integer @var{id}, provided
|
||||
the process has appropriate privileges.
|
||||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "seteuid")
|
||||
@deffn primitive seteuid id
|
||||
Sets the effective user ID to the integer @var{id}, provided the process
|
||||
has appropriate privileges. If effective IDs are not supported, the
|
||||
|
@ -1190,7 +1111,6 @@ system supports effective IDs.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setegid")
|
||||
@deffn primitive setegid id
|
||||
Sets the effective group ID to the integer @var{id}, provided the process
|
||||
has appropriate privileges. If effective IDs are not supported, the
|
||||
|
@ -1199,13 +1119,11 @@ system supports effective IDs.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getpgrp")
|
||||
@deffn primitive getpgrp
|
||||
Return an integer representing the current process group ID.
|
||||
This is the POSIX definition, not BSD.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setpgid")
|
||||
@deffn primitive setpgid pid pgid
|
||||
Move the process @var{pid} into the process group @var{pgid}. @var{pid} or
|
||||
@var{pgid} must be integers: they can be zero to indicate the ID of the
|
||||
|
@ -1214,7 +1132,6 @@ Fails on systems that do not support job control.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setsid")
|
||||
@deffn primitive setsid
|
||||
Creates a new session. The current process becomes the session leader
|
||||
and is put in a new process group. The process will be detached
|
||||
|
@ -1222,7 +1139,6 @@ from its controlling terminal if it has one.
|
|||
The return value is an integer representing the new process group ID.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "waitpid")
|
||||
@deffn primitive waitpid pid [options]
|
||||
This procedure collects status information from a child process which
|
||||
has terminated or (optionally) stopped. Normally it will
|
||||
|
@ -1271,26 +1187,22 @@ The following three
|
|||
functions can be used to decode the process status code returned
|
||||
by @code{waitpid}.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "status:exit-val")
|
||||
@deffn primitive status:exit-val status
|
||||
Return the exit status value, as would be set if a process
|
||||
ended normally through a call to @code{exit} or @code{_exit},
|
||||
if any, otherwise @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "status:term-sig")
|
||||
@deffn primitive status:term-sig status
|
||||
Return the signal number which terminated the process, if any,
|
||||
otherwise @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "status:stop-sig")
|
||||
@deffn primitive status:stop-sig status
|
||||
Return the signal number which stopped the process, if any,
|
||||
otherwise @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "system")
|
||||
@deffn primitive system [cmd]
|
||||
Execute @var{cmd} using the operating system's "command
|
||||
processor". Under Unix this is usually the default shell
|
||||
|
@ -1301,14 +1213,12 @@ If @code{system} is called without arguments, return a boolean
|
|||
indicating whether the command processor is available.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-exit")
|
||||
@deffn primitive primitive-exit [status]
|
||||
Terminate the current process without unwinding the Scheme stack.
|
||||
This is would typically be useful after a fork. The exit status
|
||||
is @var{status} if supplied, otherwise zero.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "execl")
|
||||
@deffn primitive execl filename . args
|
||||
Executes the file named by @var{path} as a new process image.
|
||||
The remaining arguments are supplied to the process; from a C program
|
||||
|
@ -1323,7 +1233,6 @@ This procedure is currently implemented using the @code{execv} system
|
|||
call, but we call it @code{execl} because of its Scheme calling interface.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "execlp")
|
||||
@deffn primitive execlp filename . args
|
||||
Similar to @code{execl}, however if
|
||||
@var{filename} does not contain a slash
|
||||
|
@ -1334,7 +1243,6 @@ This procedure is currently implemented using the @code{execvp} system
|
|||
call, but we call it @code{execlp} because of its Scheme calling interface.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "execle")
|
||||
@deffn primitive execle filename env . args
|
||||
Similar to @code{execl}, but the environment of the new process is
|
||||
specified by @var{env}, which must be a list of strings as returned by the
|
||||
|
@ -1344,7 +1252,6 @@ This procedure is currently implemented using the @code{execve} system
|
|||
call, but we call it @code{execle} because of its Scheme calling interface.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-fork")
|
||||
@deffn primitive primitive-fork
|
||||
Creates a new "child" process by duplicating the current "parent" process.
|
||||
In the child the return value is 0. In the parent the return value is
|
||||
|
@ -1354,7 +1261,6 @@ This procedure has been renamed from @code{fork} to avoid a naming conflict
|
|||
with the scsh fork.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "nice")
|
||||
@deffn primitive nice incr
|
||||
Increment the priority of the current process by @var{incr}. A higher
|
||||
priority value means that the process runs less often.
|
||||
|
@ -1366,7 +1272,6 @@ The return value is unspecified.
|
|||
|
||||
Procedures to raise, handle and wait for signals.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "kill")
|
||||
@deffn primitive kill pid sig
|
||||
Sends a signal to the specified process or group of processes.
|
||||
|
||||
|
@ -1397,13 +1302,11 @@ Interrupt signal.
|
|||
@end defvar
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "raise")
|
||||
@deffn primitive raise sig
|
||||
Sends a specified signal @var{sig} to the current process, where
|
||||
@var{sig} is as described for the kill procedure.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sigaction")
|
||||
@deffn primitive sigaction signum [handler [flags]]
|
||||
Install or report the signal handler for a specified signal.
|
||||
|
||||
|
@ -1433,13 +1336,11 @@ provide solutions to the problem of consistent access to data
|
|||
structures.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "restore-signals")
|
||||
@deffn primitive restore-signals
|
||||
Return all signal handlers to the values they had before any call to
|
||||
@code{sigaction} was made. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "alarm")
|
||||
@deffn primitive alarm i
|
||||
Set a timer to raise a @code{SIGALRM} signal after the specified
|
||||
number of seconds (an integer). It's advisable to install a signal
|
||||
|
@ -1452,21 +1353,18 @@ if any. The new value replaces the previous alarm. If there was
|
|||
no previous alarm, the return value is zero.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "pause")
|
||||
@deffn primitive pause
|
||||
Pause the current process (thread?) until a signal arrives whose
|
||||
action is to either terminate the current process or invoke a
|
||||
handler procedure. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sleep")
|
||||
@deffn primitive sleep i
|
||||
Wait for the given number of seconds (an integer) or until a signal
|
||||
arrives. The return value is zero if the time elapses or the number
|
||||
of seconds remaining otherwise.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "usleep")
|
||||
@deffn primitive usleep i
|
||||
Sleep for I microseconds. @code{usleep} is not available on
|
||||
all platforms.
|
||||
|
@ -1475,25 +1373,21 @@ all platforms.
|
|||
@node Terminals and Ptys
|
||||
@section Terminals and Ptys
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "isatty?")
|
||||
@deffn primitive isatty? port
|
||||
Return @code{#t} if @var{port} is using a serial non--file
|
||||
device, otherwise @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "ttyname")
|
||||
@deffn primitive ttyname port
|
||||
Return a string with the name of the serial terminal device
|
||||
underlying @var{port}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "ctermid")
|
||||
@deffn primitive ctermid
|
||||
Return a string containing the file name of the controlling
|
||||
terminal for the current process.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "tcgetpgrp")
|
||||
@deffn primitive tcgetpgrp port
|
||||
Return the process group ID of the foreground process group
|
||||
associated with the terminal open on the file descriptor
|
||||
|
@ -1506,7 +1400,6 @@ terminated, and no other job has yet been moved into the
|
|||
foreground.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "tcsetpgrp")
|
||||
@deffn primitive tcsetpgrp port pgid
|
||||
Set the foreground process group ID for the terminal used by the file
|
||||
descriptor underlying @var{port} to the integer @var{pgid}.
|
||||
|
@ -1569,7 +1462,6 @@ the database routines since they are not reentrant.
|
|||
|
||||
@subsubsection Address Conversion
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "inet-aton")
|
||||
@deffn primitive inet-aton address
|
||||
Converts a string containing an Internet host address in the
|
||||
traditional dotted decimal notation into an integer.
|
||||
|
@ -1578,7 +1470,6 @@ traditional dotted decimal notation into an integer.
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "inet-ntoa")
|
||||
@deffn primitive inet-ntoa inetid
|
||||
Converts an integer Internet host address into a string with
|
||||
the traditional dotted decimal representation.
|
||||
|
@ -1587,7 +1478,6 @@ the traditional dotted decimal representation.
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "inet-netof")
|
||||
@deffn primitive inet-netof address
|
||||
Return the network number part of the given integer Internet
|
||||
address.
|
||||
|
@ -1596,7 +1486,6 @@ address.
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "inet-lnaof")
|
||||
@deffn primitive inet-lnaof address
|
||||
Return the local-address-with-network part of the given
|
||||
Internet address.
|
||||
|
@ -1605,7 +1494,6 @@ Internet address.
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "inet-makeaddr")
|
||||
@deffn primitive inet-makeaddr net lna
|
||||
Makes an Internet host address by combining the network number
|
||||
@var{net} with the local-address-within-network number
|
||||
|
@ -1643,7 +1531,6 @@ The list of network addresses associated with @var{host}.
|
|||
|
||||
The following procedures are used to search the host database:
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "gethost")
|
||||
@deffn primitive gethost [host]
|
||||
@deffnx procedure gethostbyname hostname
|
||||
@deffnx procedure gethostbyaddr address
|
||||
|
@ -1680,7 +1567,6 @@ This procedure may not be used before @code{sethostent} has been called.
|
|||
Close the stream used by @code{gethostent}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sethost")
|
||||
@deffn primitive sethost [stayopen]
|
||||
If @var{stayopen} is omitted, this is equivalent to @code{endhostent}.
|
||||
Otherwise it is equivalent to @code{sethostent stayopen}.
|
||||
|
@ -1706,7 +1592,6 @@ The network number.
|
|||
|
||||
The following procedures are used to search the network database:
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getnet")
|
||||
@deffn primitive getnet [net]
|
||||
@deffnx procedure getnetbyname net-name
|
||||
@deffnx procedure getnetbyaddr net-number
|
||||
|
@ -1737,7 +1622,6 @@ Return the next entry from the network database.
|
|||
Close the stream used by @code{getnetent}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setnet")
|
||||
@deffn primitive setnet [stayopen]
|
||||
If @var{stayopen} is omitted, this is equivalent to @code{endnetent}.
|
||||
Otherwise it is equivalent to @code{setnetent stayopen}.
|
||||
|
@ -1760,7 +1644,6 @@ The protocol number.
|
|||
|
||||
The following procedures are used to search the protocol database:
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getproto")
|
||||
@deffn primitive getproto [protocol]
|
||||
@deffnx procedure getprotobyname name
|
||||
@deffnx procedure getprotobynumber number
|
||||
|
@ -1790,7 +1673,6 @@ Return the next entry from the protocol database.
|
|||
Close the stream used by @code{getprotoent}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setproto")
|
||||
@deffn primitive setproto [stayopen]
|
||||
If @var{stayopen} is omitted, this is equivalent to @code{endprotoent}.
|
||||
Otherwise it is equivalent to @code{setprotoent stayopen}.
|
||||
|
@ -1817,7 +1699,6 @@ in the database under different protocol names.
|
|||
|
||||
The following procedures are used to search the service database:
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getserv")
|
||||
@deffn primitive getserv [name [protocol]]
|
||||
@deffnx procedure getservbyname name protocol
|
||||
@deffnx procedure getservbyport port protocol
|
||||
|
@ -1851,7 +1732,6 @@ Return the next entry from the services database.
|
|||
Close the stream used by @code{getservent}. The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setserv")
|
||||
@deffn primitive setserv [stayopen]
|
||||
If @var{stayopen} is omitted, this is equivalent to @code{endservent}.
|
||||
Otherwise it is equivalent to @code{setservent stayopen}.
|
||||
|
@ -1871,7 +1751,6 @@ are always held in host order at the Scheme level. The procedures in
|
|||
this section automatically convert between host and network order when
|
||||
required. The arguments and return values are thus in host order.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "socket")
|
||||
@deffn primitive socket family style proto
|
||||
Return a new socket port of the type specified by @var{family},
|
||||
@var{style} and @var{protocol}. All three parameters are
|
||||
|
@ -1886,7 +1765,6 @@ A single socket port cannot by used for communication until it
|
|||
has been connected to another socket.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "socketpair")
|
||||
@deffn primitive socketpair family style proto
|
||||
Return a pair of connected (but unnamed) socket ports of the
|
||||
type specified by @var{family}, @var{style} and @var{protocol}.
|
||||
|
@ -1895,7 +1773,6 @@ family. Zero is likely to be the only meaningful value for
|
|||
@var{protocol}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getsockopt")
|
||||
@deffn primitive getsockopt sock level optname
|
||||
Return the value of a particular socket option for the socket
|
||||
port @var{socket}. @var{level} is an integer code for type of
|
||||
|
@ -1907,7 +1784,6 @@ The returned value is typically an integer but @code{SO_LINGER}
|
|||
returns a pair of integers.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setsockopt")
|
||||
@deffn primitive setsockopt sock level optname value
|
||||
Sets the value of a particular socket option for the socket
|
||||
port @var{socket}. @var{level} is an integer code for type of option
|
||||
|
@ -1922,7 +1798,6 @@ be a pair.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "shutdown")
|
||||
@deffn primitive shutdown sock how
|
||||
Sockets can be closed simply by using @code{close-port}. The
|
||||
@code{shutdown} procedure allows reception or tranmission on a
|
||||
|
@ -1943,7 +1818,6 @@ Stop both reception and transmission.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "connect")
|
||||
@deffn primitive connect sock fam address . args
|
||||
Initiates a connection from @var{socket} to the address
|
||||
specified by @var{address} and possibly @var{arg @dots{}}. The format
|
||||
|
@ -1961,7 +1835,6 @@ must be a single integer port number.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "bind")
|
||||
@deffn primitive bind sock fam address . args
|
||||
Assigns an address to the socket port @var{socket}.
|
||||
Generally this only needs to be done for server sockets,
|
||||
|
@ -2001,7 +1874,6 @@ No address.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "listen")
|
||||
@deffn primitive listen sock backlog
|
||||
This procedure enables @var{socket} to accept connection
|
||||
requests. @var{backlog} is an integer specifying
|
||||
|
@ -2012,7 +1884,6 @@ server calls @code{accept} to accept a connection from the queue.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "accept")
|
||||
@deffn primitive accept sock
|
||||
Accepts a connection on a bound, listening socket @var{socket}. If there
|
||||
are no pending connections in the queue, it waits until
|
||||
|
@ -2048,14 +1919,12 @@ If the socket family is @code{AF_INET}, returns the Internet port
|
|||
number.
|
||||
@end table
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getsockname")
|
||||
@deffn primitive getsockname sock
|
||||
Return the address of @var{socket}, in the same form as the
|
||||
object returned by @code{accept}. On many systems the address
|
||||
of a socket in the @code{AF_FILE} namespace cannot be read.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "getpeername")
|
||||
@deffn primitive getpeername sock
|
||||
Return the address of the socket that the socket @var{socket}
|
||||
is connected to, in the same form as the object returned by
|
||||
|
@ -2063,7 +1932,6 @@ is connected to, in the same form as the object returned by
|
|||
@code{AF_FILE} namespace cannot be read.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "recv!")
|
||||
@deffn primitive recv! sock buf [flags]
|
||||
Receives data from the socket port @var{socket}. @var{socket} must already
|
||||
be bound to the address from which data is to be received.
|
||||
|
@ -2082,7 +1950,6 @@ Note that the data is read directly from the socket file descriptor:
|
|||
any unread buffered port data is ignored.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "send")
|
||||
@deffn primitive send sock message [flags]
|
||||
Transmits the string @var{message} on the socket port @var{socket}.
|
||||
@var{socket} must already be bound to a destination address. The
|
||||
|
@ -2095,7 +1962,6 @@ Note that the data is written directly to the socket file descriptor:
|
|||
any unflushed buffered port data is ignored.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "recvfrom!")
|
||||
@deffn primitive recvfrom! sock str [flags [start [end]]]
|
||||
Return data from the socket port @var{socket} and also
|
||||
information about where the data was received from.
|
||||
|
@ -2116,7 +1982,6 @@ Note that the data is read directly from the socket file
|
|||
descriptor: any unread buffered port data is ignored.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sendto")
|
||||
@deffn primitive sendto sock message fam address . args_and_flags
|
||||
Transmits the string @var{message} on the socket port @var{socket}. The
|
||||
destination address is specified using the @var{family}, @var{address} and
|
||||
|
@ -2136,28 +2001,24 @@ between "host" and "network" order. Although the procedures above do
|
|||
this automatically for addresses, the conversion will still need to
|
||||
be done when sending or receiving encoded integer data from the network.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "htons")
|
||||
@deffn primitive htons in
|
||||
Return a new integer from @var{value} by converting from host
|
||||
to network order. @var{value} must be within the range of a C
|
||||
unsigned short integer.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "ntohs")
|
||||
@deffn primitive ntohs in
|
||||
Return a new integer from @var{value} by converting from
|
||||
network to host order. @var{value} must be within the range of
|
||||
a C unsigned short integer.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "htonl")
|
||||
@deffn primitive htonl in
|
||||
Return a new integer from @var{value} by converting from host
|
||||
to network order. @var{value} must be within the range of a C
|
||||
unsigned long integer.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "ntohl")
|
||||
@deffn primitive ntohl in
|
||||
Return a new integer from @var{value} by converting from
|
||||
network to host order. @var{value} must be within the range of
|
||||
|
@ -2183,7 +2044,6 @@ These procedures are inconvenient to use at present, but consider:
|
|||
@node System Identification
|
||||
@section System Identification
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "uname")
|
||||
@deffn primitive uname
|
||||
Return an object with some information about the computer
|
||||
system the program is running on.
|
||||
|
@ -2221,7 +2081,6 @@ no other easy or unambiguous way of detecting such features.
|
|||
@node Locales
|
||||
@section Locales
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setlocale")
|
||||
@deffn primitive setlocale category [locale]
|
||||
If @var{locale} is omitted, return the current value of the
|
||||
specified locale category as a system-dependent string.
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
@section Querying variable bindings
|
||||
|
||||
@c NJFIXME explain [env]
|
||||
@c docstring begin (texi-doc-string "guile" "defined?")
|
||||
@deffn primitive defined? sym [env]
|
||||
Return @code{#t} if @var{sym} is defined in the top-level environment.
|
||||
@end deffn
|
||||
|
|
|
@ -88,7 +88,6 @@ Instead of using @code{call-with-current-continuation}, the exception
|
|||
primitives documented here are implemented as built-ins that take
|
||||
advantage of the @emph{upward only} nature of exceptions.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "catch")
|
||||
@deffn primitive catch key thunk handler
|
||||
Invoke @var{thunk} in the dynamic context of @var{handler} for
|
||||
exceptions matching @var{key}. If thunk throws to the symbol
|
||||
|
@ -106,7 +105,6 @@ If the key is @code{#t}, then a throw to @emph{any} symbol will
|
|||
match this call to @code{catch}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "throw")
|
||||
@deffn primitive throw key . args
|
||||
Invoke the catch form matching @var{key}, passing @var{args} to the
|
||||
@var{handler}.
|
||||
|
@ -117,7 +115,6 @@ Invoke the catch form matching @var{key}, passing @var{args} to the
|
|||
If there is no handler at all, an error is signaled.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "lazy-catch")
|
||||
@deffn primitive lazy-catch key thunk handler
|
||||
This behaves exactly like @code{catch}, except that it does
|
||||
not unwind the stack (this is the major difference), and if
|
||||
|
@ -139,7 +136,6 @@ displaying @var{msg} and writing @var{args}.
|
|||
@end deffn
|
||||
@c end
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "scm-error")
|
||||
@deffn primitive scm-error key subr message args data
|
||||
Raise an error with key @var{key}. @var{subr} can be a string
|
||||
naming the procedure associated with the error, or @code{#f}.
|
||||
|
@ -156,7 +152,6 @@ should be a list containing the Unix signal number; otherwise
|
|||
it will usually be @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "strerror")
|
||||
@deffn primitive strerror err
|
||||
Return the Unix error message corresponding to @var{err}, which
|
||||
must be an integer value.
|
||||
|
@ -177,7 +172,6 @@ if an exception occurs then @code{#f} is returned instead.
|
|||
be reviewed]
|
||||
|
||||
@rnindex dynamic-wind
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-wind")
|
||||
@deffn primitive dynamic-wind in_guard thunk out_guard
|
||||
All three arguments must be 0-argument procedures.
|
||||
@var{in_guard} is called, then @var{thunk}, then
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -6,7 +6,6 @@
|
|||
from the appendix describing the debugger UI. The intro
|
||||
should have a pointer to the UI appendix.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "display-error")
|
||||
@deffn primitive display-error stack port subr message args rest
|
||||
Display an error message to the output port @var{port}.
|
||||
@var{stack} is the saved stack for the error, @var{subr} is
|
||||
|
@ -17,14 +16,12 @@ the list @var{args} accordingly. @var{rest} is currently
|
|||
ignored.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "display-application")
|
||||
@deffn primitive display-application frame [port [indent]]
|
||||
Display a procedure application @var{frame} to the output port
|
||||
@var{port}. @var{indent} specifies the indentation of the
|
||||
output.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "display-backtrace")
|
||||
@deffn primitive display-backtrace stack port [first [depth]]
|
||||
Display a backtrace to the output port @var{port}. @var{stack}
|
||||
is the stack to take the backtrace from, @var{first} specifies
|
||||
|
@ -33,13 +30,11 @@ to display. Both @var{first} and @var{depth} can be @code{#f},
|
|||
which means that default values will be used.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "backtrace")
|
||||
@deffn primitive backtrace
|
||||
Display a backtrace of the stack saved by the last error
|
||||
to the current output port.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "malloc-stats")
|
||||
@deffn primitive malloc-stats
|
||||
Return an alist ((@var{what} . @var{n}) ...) describing number
|
||||
of malloced objects.
|
||||
|
@ -48,119 +43,97 @@ of malloced objects.
|
|||
allocated.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "debug-options-interface")
|
||||
@deffn primitive debug-options-interface [setting]
|
||||
Option interface for the debug options. Instead of using
|
||||
this procedure directly, use the procedures @code{debug-enable},
|
||||
@code{debug-disable}, @code{debug-set!} and @var{debug-options}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "with-traps")
|
||||
@deffn primitive with-traps thunk
|
||||
Call @var{thunk} with traps enabled.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "memoized?")
|
||||
@deffn primitive memoized? obj
|
||||
Return @code{#t} if @var{obj} is memoized.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unmemoize")
|
||||
@deffn primitive unmemoize m
|
||||
Unmemoize the memoized expression @var{m},
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "memoized-environment")
|
||||
@deffn primitive memoized-environment m
|
||||
Return the environment of the memoized expression @var{m}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-name")
|
||||
@deffn primitive procedure-name proc
|
||||
Return the name of the procedure @var{proc}
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-source")
|
||||
@deffn primitive procedure-source proc
|
||||
Return the source of the procedure @var{proc}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-environment")
|
||||
@deffn primitive procedure-environment proc
|
||||
Return the environment of the procedure @var{proc}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "debug-object?")
|
||||
@deffn primitive debug-object? obj
|
||||
Return @code{#t} if @var{obj} is a debug object.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-arguments")
|
||||
@deffn primitive frame-arguments frame
|
||||
Return the arguments of @var{frame}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-evaluating-args?")
|
||||
@deffn primitive frame-evaluating-args? frame
|
||||
Return @code{#t} if @var{frame} contains evaluated arguments.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-next")
|
||||
@deffn primitive frame-next frame
|
||||
Return the next frame of @var{frame}, or @code{#f} if
|
||||
@var{frame} is the last frame in its stack.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-number")
|
||||
@deffn primitive frame-number frame
|
||||
Return the frame number of @var{frame}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-overflow?")
|
||||
@deffn primitive frame-overflow? frame
|
||||
Return @code{#t} if @var{frame} is an overflow frame.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-previous")
|
||||
@deffn primitive frame-previous frame
|
||||
Return the previous frame of @var{frame}, or @code{#f} if
|
||||
@var{frame} is the first frame in its stack.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-procedure")
|
||||
@deffn primitive frame-procedure frame
|
||||
Return the procedure for @var{frame}, or @code{#f} if no
|
||||
procedure is associated with @var{frame}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-procedure?")
|
||||
@deffn primitive frame-procedure? frame
|
||||
Return @code{#t} if a procedure is associated with @var{frame}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-real?")
|
||||
@deffn primitive frame-real? frame
|
||||
Return @code{#t} if @var{frame} is a real frame.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame-source")
|
||||
@deffn primitive frame-source frame
|
||||
Return the source of @var{frame}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "frame?")
|
||||
@deffn primitive frame? obj
|
||||
Return @code{#t} if @var{obj} is a stack frame.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "last-stack-frame")
|
||||
@deffn primitive last-stack-frame obj
|
||||
Return a stack which consists of a single frame, which is the
|
||||
last stack frame for @var{obj}. @var{obj} must be either a
|
||||
debug object or a continuation.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-stack")
|
||||
@deffn primitive make-stack obj . args
|
||||
Create a new stack. If @var{obj} is @code{#t}, the current
|
||||
evaluation stack is used for creating the stack frames,
|
||||
|
@ -170,22 +143,18 @@ either a debug object or a continuation).
|
|||
resulting stack will be narrowed.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "stack-id")
|
||||
@deffn primitive stack-id stack
|
||||
Return the identifier given to @var{stack} by @code{start-stack}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "stack-length")
|
||||
@deffn primitive stack-length stack
|
||||
Return the length of @var{stack}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "stack-ref")
|
||||
@deffn primitive stack-ref stack i
|
||||
Return the @var{i}'th frame from @var{stack}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "stack?")
|
||||
@deffn primitive stack? obj
|
||||
Return @code{#t} if @var{obj} is a calling stack.
|
||||
@end deffn
|
||||
|
|
|
@ -52,7 +52,6 @@ loading and evaluating Scheme code at run time.
|
|||
@node Reader Extensions
|
||||
@subsection Reader Extensions
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "read-hash-extend")
|
||||
@deffn primitive read-hash-extend chr proc
|
||||
Install the procedure @var{proc} for reading expressions
|
||||
starting with the character sequence @code{#} and @var{chr}.
|
||||
|
@ -66,7 +65,6 @@ returned will be the return value of @code{read}.
|
|||
@section Reading Scheme Code
|
||||
|
||||
@rnindex read
|
||||
@c docstring begin (texi-doc-string "guile" "read")
|
||||
@deffn primitive read [port]
|
||||
Read an s-expression from the input port @var{port}, or from
|
||||
the current input port if @var{port} is not specified.
|
||||
|
@ -101,7 +99,6 @@ options and switches them on, @code{read-disable} switches them off.
|
|||
@code{read-set!} can be used to set an option to a specific value.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "read-options-interface")
|
||||
@deffn primitive read-options-interface [setting]
|
||||
Option interface for the read options. Instead of using
|
||||
this procedure directly, use the procedures @code{read-enable},
|
||||
|
@ -114,14 +111,12 @@ this procedure directly, use the procedures @code{read-enable},
|
|||
|
||||
@rnindex eval
|
||||
@c ARGFIXME environment/environment specifier
|
||||
@c docstring begin (texi-doc-string "guile" "eval")
|
||||
@deffn primitive eval exp environment
|
||||
Evaluate @var{exp}, a list representing a Scheme expression, in the
|
||||
environment given by @var{environment specifier}.
|
||||
@end deffn
|
||||
|
||||
@rnindex interaction-environment
|
||||
@c docstring begin (texi-doc-string "guile" "interaction-environment")
|
||||
@deffn primitive interaction-environment
|
||||
Return a specifier for the environment that contains
|
||||
implementation--defined bindings, typically a superset of those
|
||||
|
@ -130,7 +125,6 @@ return the environment in which the implementation would
|
|||
evaluate expressions dynamically typed by the user.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "eval-string")
|
||||
@deffn primitive eval-string string
|
||||
Evaluate @var{string} as the text representation of a Scheme
|
||||
form or forms, and return whatever value they produce.
|
||||
|
@ -138,7 +132,6 @@ Evaluation takes place in the environment returned by the
|
|||
procedure @code{interaction-environment}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "apply:nconc2last")
|
||||
@deffn primitive apply:nconc2last lst
|
||||
Given a list (@var{arg1} @dots{} @var{args}), this function
|
||||
conses the @var{arg1} @dots{} arguments onto the front of
|
||||
|
@ -189,7 +182,6 @@ any code is loaded. See documentation for @code{%load-hook} later in
|
|||
this section.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-load")
|
||||
@deffn primitive primitive-load filename
|
||||
Load the file named @var{filename} and evaluate its contents in
|
||||
the top-level environment. The load paths are not searched;
|
||||
|
@ -200,7 +192,6 @@ that will be called before any code is loaded. See the
|
|||
documentation for @code{%load-hook} later in this section.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-load-path")
|
||||
@deffn primitive primitive-load-path filename
|
||||
Search @var{%load-path} for the file named @var{filename} and
|
||||
load it into the top-level environment. If @var{filename} is a
|
||||
|
@ -208,7 +199,6 @@ relative pathname and is not found in the list of search paths,
|
|||
an error is signalled.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%search-load-path")
|
||||
@deffn primitive %search-load-path filename
|
||||
Search @var{%load-path} for the file named @var{filename},
|
||||
which must be readable by the current user. If @var{filename}
|
||||
|
@ -235,7 +225,6 @@ was passed to @code{primitive-load}.
|
|||
|
||||
@end defvar
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "current-load-port")
|
||||
@deffn primitive current-load-port
|
||||
Return the current-load-port.
|
||||
The load port is used internally by @code{primitive-load}.
|
||||
|
@ -254,14 +243,12 @@ list @code{("" ".scm")}.
|
|||
|
||||
[delay]
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "promise?")
|
||||
@deffn primitive promise? obj
|
||||
Return true if @var{obj} is a promise, i.e. a delayed computation
|
||||
(@pxref{Delayed evaluation,,,r4rs.info,The Revised^4 Report on Scheme}).
|
||||
@end deffn
|
||||
|
||||
@rnindex force
|
||||
@c docstring begin (texi-doc-string "guile" "force")
|
||||
@deffn primitive force x
|
||||
If the promise @var{x} has not been computed yet, compute and
|
||||
return @var{x}, otherwise just return the previously computed
|
||||
|
@ -274,7 +261,6 @@ value.
|
|||
|
||||
[the-environment]
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "local-eval")
|
||||
@deffn primitive local-eval exp [env]
|
||||
Evaluate @var{exp} in its environment. If @var{env} is supplied,
|
||||
it is the environment in which to evaluate @var{exp}. Otherwise,
|
||||
|
@ -318,7 +304,6 @@ options and switches them on, @code{eval-disable} switches them off.
|
|||
@code{eval-set!} can be used to set an option to a specific value.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "eval-options-interface")
|
||||
@deffn primitive eval-options-interface [setting]
|
||||
Option interface for the evaluation options. Instead of using
|
||||
this procedure directly, use the procedures @code{eval-enable},
|
||||
|
@ -349,7 +334,6 @@ options and switches them on, @code{trap-disable} switches them off.
|
|||
@code{trap-set!} can be used to set an option to a specific value.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "evaluator-traps-interface")
|
||||
@deffn primitive evaluator-traps-interface [setting]
|
||||
Option interface for the evaluator trap options.
|
||||
@end deffn
|
||||
|
|
|
@ -33,7 +33,6 @@ that simulate ports in software. @dfn{Soft ports} and @dfn{string
|
|||
ports} are two interesting and powerful examples of this technique.
|
||||
|
||||
@rnindex input-port?
|
||||
@c docstring begin (texi-doc-string "guile" "input-port?")
|
||||
@deffn primitive input-port? x
|
||||
Return @code{#t} if @var{x} is an input port, otherwise return
|
||||
@code{#f}. Any object satisfying this predicate also satisfies
|
||||
|
@ -41,14 +40,12 @@ Return @code{#t} if @var{x} is an input port, otherwise return
|
|||
@end deffn
|
||||
|
||||
@rnindex output-port?
|
||||
@c docstring begin (texi-doc-string "guile" "output-port?")
|
||||
@deffn primitive output-port? x
|
||||
Return @code{#t} if @var{x} is an output port, otherwise return
|
||||
@code{#f}. Any object satisfying this predicate also satisfies
|
||||
@code{port?}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port?")
|
||||
@deffn primitive port? x
|
||||
Return a boolean indicating whether @var{x} is a port.
|
||||
Equivalent to @code{(or (input-port? @var{x}) (output-port?
|
||||
|
@ -62,14 +59,12 @@ Equivalent to @code{(or (input-port? @var{x}) (output-port?
|
|||
[Generic procedures for reading from ports.]
|
||||
|
||||
@rnindex eof-object?
|
||||
@c docstring begin (texi-doc-string "guile" "eof-object?")
|
||||
@deffn primitive eof-object? x
|
||||
Return @code{#t} if @var{x} is an end-of-file object; otherwise
|
||||
return @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@rnindex char-ready?
|
||||
@c docstring begin (texi-doc-string "guile" "char-ready?")
|
||||
@deffn primitive char-ready? [port]
|
||||
Return @code{#t} if a character is ready on input @var{port}
|
||||
and return @code{#f} otherwise. If @code{char-ready?} returns
|
||||
|
@ -87,7 +82,6 @@ interactive port that has no ready characters.}
|
|||
@end deffn
|
||||
|
||||
@rnindex read-char?
|
||||
@c docstring begin (texi-doc-string "guile" "read-char")
|
||||
@deffn primitive read-char [port]
|
||||
Return the next character available from @var{port}, updating
|
||||
@var{port} to point to the following character. If no more
|
||||
|
@ -95,7 +89,6 @@ characters are available, the end-of-file object is returned.
|
|||
@end deffn
|
||||
|
||||
@rnindex peek-char?
|
||||
@c docstring begin (texi-doc-string "guile" "peek-char")
|
||||
@deffn primitive peek-char [port]
|
||||
Return the next character available from @var{port},
|
||||
@emph{without} updating @var{port} to point to the following
|
||||
|
@ -111,7 +104,6 @@ an interactive port will hang waiting for input whenever a call
|
|||
to @code{read-char} would have hung.}
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unread-char")
|
||||
@deffn primitive unread-char cobj port
|
||||
Place @var{char} in @var{port} so that it will be read by the
|
||||
next read operation. If called multiple times, the unread characters
|
||||
|
@ -119,7 +111,6 @@ will be read again in last-in first-out order. If @var{port} is
|
|||
not supplied, the current input port is used.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unread-string")
|
||||
@deffn primitive unread-string str port
|
||||
Place the string @var{str} in @var{port} so that its characters will be
|
||||
read in subsequent read operations. If called multiple times, the
|
||||
|
@ -127,14 +118,11 @@ unread characters will be read again in last-in first-out order. If
|
|||
@var{port} is not supplied, the current-input-port is used.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "drain-input")
|
||||
@deffn primitive drain-input port
|
||||
Drain @var{port}'s read buffers (including any pushed-back
|
||||
characters) and return the content as a single string.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-column")
|
||||
@c docstring begin (texi-doc-string "guile" "port-line")
|
||||
@deffn primitive port-column port
|
||||
@deffnx primitive port-line port
|
||||
Return the current column number or line number of @var{port},
|
||||
|
@ -147,8 +135,6 @@ because lines and column numbers traditionally start with 1, and that is
|
|||
what non-programmers will find most natural.)
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-port-column!")
|
||||
@c docstring begin (texi-doc-string "guile" "set-port-line!")
|
||||
@deffn primitive set-port-column! port column
|
||||
@deffnx primitive set-port-line! port line
|
||||
Set the current column or line number of @var{port}, using the
|
||||
|
@ -195,25 +181,21 @@ end-of-file check
|
|||
|
||||
[Generic procedures for writing to ports.]
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "get-print-state")
|
||||
@deffn primitive get-print-state port
|
||||
Return the print state of the port @var{port}. If @var{port}
|
||||
has no associated print state, @code{#f} is returned.
|
||||
@end deffn
|
||||
|
||||
@rnindex newline
|
||||
@c docstring begin (texi-doc-string "guile" "newline")
|
||||
@deffn primitive newline [port]
|
||||
Send a newline to @var{port}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-with-print-state")
|
||||
@deffn primitive port-with-print-state port pstate
|
||||
Create a new port which behaves like @var{port}, but with an
|
||||
included print state @var{pstate}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "print-options-interface")
|
||||
@deffn primitive print-options-interface [setting]
|
||||
Option interface for the print options. Instead of using
|
||||
this procedure directly, use the procedures
|
||||
|
@ -221,7 +203,6 @@ this procedure directly, use the procedures
|
|||
and @code{print-options}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "simple-format")
|
||||
@deffn primitive simple-format destination message . args
|
||||
Write @var{message} to @var{destination}, defaulting to
|
||||
the current output port.
|
||||
|
@ -237,13 +218,11 @@ containing the formatted text. Does not add a trailing newline.
|
|||
@end deffn
|
||||
|
||||
@rnindex write-char
|
||||
@c docstring begin (texi-doc-string "guile" "write-char")
|
||||
@deffn primitive write-char chr [port]
|
||||
Send character @var{chr} to @var{port}.
|
||||
@end deffn
|
||||
|
||||
@findex fflush
|
||||
@c docstring begin (texi-doc-string "guile" "force-output")
|
||||
@deffn primitive force-output [port]
|
||||
Flush the specified output port, or the current output port if @var{port}
|
||||
is omitted. The current output buffer contents are passed to the
|
||||
|
@ -254,7 +233,6 @@ It has no effect on an unbuffered port.
|
|||
The return value is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "flush-all-ports")
|
||||
@deffn primitive flush-all-ports
|
||||
Equivalent to calling @code{force-output} on
|
||||
all open output ports. The return value is unspecified.
|
||||
|
@ -264,7 +242,6 @@ all open output ports. The return value is unspecified.
|
|||
@node Closing
|
||||
@section Closing
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "close-port")
|
||||
@deffn primitive close-port port
|
||||
Close the specified port object. Return @code{#t} if it
|
||||
successfully closes a port or @code{#f} if it was already
|
||||
|
@ -275,7 +252,6 @@ descriptors.
|
|||
@end deffn
|
||||
|
||||
@rnindex close-input-port
|
||||
@c docstring begin (texi-doc-string "guile" "close-input-port")
|
||||
@deffn primitive close-input-port port
|
||||
Close the specified input port object. The routine has no effect if
|
||||
the file has already been closed. An exception may be raised if an
|
||||
|
@ -286,7 +262,6 @@ which can close file descriptors.
|
|||
@end deffn
|
||||
|
||||
@rnindex close-output-port
|
||||
@c docstring begin (texi-doc-string "guile" "close-output-port")
|
||||
@deffn primitive close-output-port port
|
||||
Close the specified output port object. The routine has no effect if
|
||||
the file has already been closed. An exception may be raised if an
|
||||
|
@ -296,7 +271,6 @@ See also @ref{Ports and File Descriptors, close}, for a procedure
|
|||
which can close file descriptors.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-closed?")
|
||||
@deffn primitive port-closed? port
|
||||
Return @code{#t} if @var{port} is closed or @code{#f} if it is
|
||||
open.
|
||||
|
@ -306,7 +280,6 @@ open.
|
|||
@node Random Access
|
||||
@section Random Access
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "seek")
|
||||
@deffn primitive seek fd_port offset whence
|
||||
Sets the current position of @var{fd/port} to the integer
|
||||
@var{offset}, which is interpreted according to the value of
|
||||
|
@ -331,13 +304,11 @@ that the current position of a port can be obtained using:
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fseek")
|
||||
@deffn primitive fseek fd_port offset whence
|
||||
Obsolete. Almost the same as @code{seek}, but the return value
|
||||
is unspecified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "ftell")
|
||||
@deffn primitive ftell fd_port
|
||||
Return an integer representing the current position of
|
||||
@var{fd/port}, measured from the beginning. Equivalent to:
|
||||
|
@ -348,7 +319,6 @@ Return an integer representing the current position of
|
|||
|
||||
@findex truncate
|
||||
@findex ftruncate
|
||||
@c docstring begin (texi-doc-string "guile" "truncate-file")
|
||||
@deffn primitive truncate-file object [length]
|
||||
Truncates the object referred to by @var{object} to at most
|
||||
@var{length} bytes. @var{object} can be a string containing a
|
||||
|
@ -435,7 +405,6 @@ NOTE: if the scsh module is loaded then @var{delims} must be an scsh
|
|||
char-set, not a string.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "write-line")
|
||||
@deffn primitive write-line obj [port]
|
||||
Display @var{obj} and a newline character to @var{port}. If
|
||||
@var{port} is not specified, @code{(current-output-port)} is
|
||||
|
@ -450,7 +419,6 @@ Some of the abovementioned I/O functions rely on the following C
|
|||
primitives. These will mainly be of interest to people hacking Guile
|
||||
internals.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%read-delimited!")
|
||||
@deffn primitive %read-delimited! delims str gobble [port [start [end]]]
|
||||
Read characters from @var{port} into @var{str} until one of the
|
||||
characters in the @var{delims} string is encountered. If
|
||||
|
@ -468,7 +436,6 @@ at the end of file, the delimiter returned is the
|
|||
a delimiter, this value is @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%read-line")
|
||||
@deffn primitive %read-line [port]
|
||||
Read a newline-terminated line from @var{port}, allocating storage as
|
||||
necessary. The newline terminator (if any) is removed from the string,
|
||||
|
@ -496,7 +463,6 @@ If omitted, @var{port} defaults to the current output port.
|
|||
@section Default Ports for Input, Output and Errors
|
||||
|
||||
@rnindex current-input-port
|
||||
@c docstring begin (texi-doc-string "guile" "current-input-port")
|
||||
@deffn primitive current-input-port
|
||||
Return the current input port. This is the default port used
|
||||
by many input procedures. Initially, @code{current-input-port}
|
||||
|
@ -504,7 +470,6 @@ returns the @dfn{standard input} in Unix and C terminology.
|
|||
@end deffn
|
||||
|
||||
@rnindex current-output-port
|
||||
@c docstring begin (texi-doc-string "guile" "current-output-port")
|
||||
@deffn primitive current-output-port
|
||||
Return the current output port. This is the default port used
|
||||
by many output procedures. Initially,
|
||||
|
@ -512,13 +477,11 @@ by many output procedures. Initially,
|
|||
Unix and C terminology.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "current-error-port")
|
||||
@deffn primitive current-error-port
|
||||
Return the port to which errors and warnings should be sent (the
|
||||
@dfn{standard error} in Unix and C terminology).
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-current-input-port")
|
||||
@deffn primitive set-current-input-port port
|
||||
@deffnx primitive set-current-output-port port
|
||||
@deffnx primitive set-current-error-port port
|
||||
|
@ -527,12 +490,10 @@ Change the ports returned by @code{current-input-port},
|
|||
so that they use the supplied @var{port} for input or output.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-current-output-port")
|
||||
@deffn primitive set-current-output-port port
|
||||
Set the current default output port to PORT.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-current-error-port")
|
||||
@deffn primitive set-current-error-port port
|
||||
Set the current default error port to PORT.
|
||||
@end deffn
|
||||
|
@ -558,7 +519,6 @@ The following procedures are used to open file ports.
|
|||
See also @ref{Ports and File Descriptors, open}, for an interface
|
||||
to the Unix @code{open} system call.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "open-file")
|
||||
@deffn primitive open-file filename mode
|
||||
Open the file whose name is @var{filename}, and return a port
|
||||
representing that file. The attributes of the port are
|
||||
|
@ -686,7 +646,6 @@ from the continuation of these procedures, their behavior is
|
|||
implementation dependent.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-mode")
|
||||
@deffn primitive port-mode port
|
||||
Returns the port modes associated with the open port @var{port}. These
|
||||
will not necessarily be identical to the modes used when the port was
|
||||
|
@ -694,14 +653,12 @@ opened, since modes such as "append" which are used only during
|
|||
port creation are not retained.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "port-filename")
|
||||
@deffn primitive port-filename port
|
||||
Return the filename associated with @var{port}. This function returns
|
||||
the strings "standard input", "standard output" and "standard error"
|
||||
when called on the current input, output and error ports respectively.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-port-filename!")
|
||||
@deffn primitive set-port-filename! port filename
|
||||
Change the filename associated with @var{port}, using the current input
|
||||
port if none is specified. Note that this does not change the port's
|
||||
|
@ -720,14 +677,12 @@ Determine whether @var{obj} is a port that is related to a file.
|
|||
The following allow string ports to be opened by analogy to R4R*
|
||||
file port facilities:
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "call-with-output-string")
|
||||
@deffn primitive call-with-output-string proc
|
||||
Calls the one-argument procedure @var{proc} with a newly created output
|
||||
port. When the function returns, the string composed of the characters
|
||||
written into the port is returned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "call-with-input-string")
|
||||
@deffn primitive call-with-input-string string proc
|
||||
Calls the one-argument procedure @var{proc} with a newly
|
||||
created input port from which @var{string}'s contents may be
|
||||
|
@ -748,7 +703,6 @@ port set temporarily to a string port opened on the specified
|
|||
@var{string}. The value yielded by @var{thunk} is returned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "open-input-string")
|
||||
@deffn primitive open-input-string str
|
||||
Take a string and return an input port that delivers characters
|
||||
from the string. The port can be closed by
|
||||
|
@ -756,7 +710,6 @@ from the string. The port can be closed by
|
|||
by the garbage collector if it becomes inaccessible.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "open-output-string")
|
||||
@deffn primitive open-output-string
|
||||
Return an output port that will accumulate characters for
|
||||
retrieval by @code{get-output-string}. The port can be closed
|
||||
|
@ -765,7 +718,6 @@ will be reclaimed by the garbage collector if it becomes
|
|||
inaccessible.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "get-output-string")
|
||||
@deffn primitive get-output-string port
|
||||
Given an output port created by @code{open-output-string},
|
||||
return a string consisting of the characters that have been
|
||||
|
@ -784,7 +736,6 @@ but trying to extract the file descriptor number will fail.
|
|||
A @dfn{soft-port} is a port based on a vector of procedures capable of
|
||||
accepting or delivering characters. It allows emulation of I/O ports.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-soft-port")
|
||||
@deffn primitive make-soft-port pv modes
|
||||
Return a port capable of receiving or delivering characters as
|
||||
specified by the @var{modes} string (@pxref{File Ports,
|
||||
|
@ -831,7 +782,6 @@ For example:
|
|||
This kind of port causes any data to be discarded when written to, and
|
||||
always returns the end-of-file object when read from.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%make-void-port")
|
||||
@deffn primitive %make-void-port mode
|
||||
Create and return a new void port. A void port acts like
|
||||
/dev/null. The @var{mode} argument
|
||||
|
|
|
@ -15,25 +15,21 @@
|
|||
[FIXME: this is pasted in from Tom Lord's original guile.texi and should
|
||||
be reviewed]
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "gc")
|
||||
@deffn primitive gc
|
||||
Scans all of SCM objects and reclaims for further use those that are
|
||||
no longer accessible.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "gc-stats")
|
||||
@deffn primitive gc-stats
|
||||
Return an association list of statistics about Guile's current
|
||||
use of storage.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "object-address")
|
||||
@deffn primitive object-address obj
|
||||
Return an integer that for the lifetime of @var{obj} is uniquely
|
||||
returned by this function for @var{obj}
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unhash-name")
|
||||
@deffn primitive unhash-name name
|
||||
Flushes the glocs for @var{name}, or all glocs if @var{name}
|
||||
is @code{#t}.
|
||||
|
@ -88,7 +84,6 @@ they constitute a doubly-weak table has to be used.
|
|||
@node Weak key hashes
|
||||
@subsection Weak key hashes
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-weak-key-hash-table")
|
||||
@deffn primitive make-weak-key-hash-table size
|
||||
@deffnx primitive make-weak-value-hash-table size
|
||||
@deffnx primitive make-doubly-weak-hash-table size
|
||||
|
@ -99,7 +94,6 @@ You can modify weak hash tables in exactly the same way you
|
|||
would modify regular hash tables. (@pxref{Hash Tables})
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "weak-key-hash-table?")
|
||||
@deffn primitive weak-key-hash-table? obj
|
||||
@deffnx primitive weak-value-hash-table? obj
|
||||
@deffnx primitive doubly-weak-hash-table? obj
|
||||
|
@ -108,19 +102,15 @@ table. Note that a doubly weak hash table is neither a weak key
|
|||
nor a weak value hash table.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-weak-value-hash-table")
|
||||
@deffn primitive make-weak-value-hash-table k
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "weak-value-hash-table?")
|
||||
@deffn primitive weak-value-hash-table? x
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-doubly-weak-hash-table")
|
||||
@deffn primitive make-doubly-weak-hash-table k
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "doubly-weak-hash-table?")
|
||||
@deffn primitive doubly-weak-hash-table? x
|
||||
@end deffn
|
||||
|
||||
|
@ -131,7 +121,6 @@ nor a weak value hash table.
|
|||
Weak vectors are mainly useful in Guile's implementation of weak hash
|
||||
tables.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-weak-vector")
|
||||
@deffn primitive make-weak-vector size [fill]
|
||||
Return a weak vector with @var{size} elements. If the optional
|
||||
argument @var{fill} is given, all entries in the vector will be
|
||||
|
@ -139,8 +128,6 @@ set to @var{fill}. The default value for @var{fill} is the
|
|||
empty list.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "weak-vector")
|
||||
@c docstring begin (texi-doc-string "guile" "list->weak-vector")
|
||||
@deffn primitive weak-vector . l
|
||||
@deffnx primitive list->weak-vector l
|
||||
Construct a weak vector from a list: @code{weak-vector} uses
|
||||
|
@ -149,7 +136,6 @@ its only argument @var{l} (a list) to construct a weak vector
|
|||
the same way @code{list->vector} would.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "weak-vector?")
|
||||
@deffn primitive weak-vector? obj
|
||||
Return @code{#t} if @var{obj} is a weak vector. Note that all
|
||||
weak hashes are also weak vectors.
|
||||
|
@ -159,7 +145,6 @@ weak hashes are also weak vectors.
|
|||
@node Guardians
|
||||
@section Guardians
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-guardian")
|
||||
@deffn primitive make-guardian [greedy?]
|
||||
Create a new guardian.
|
||||
A guardian protects a set of objects from garbage collection,
|
||||
|
@ -207,29 +192,24 @@ Return @code{#t} if @var{guardian} has been destroyed, otherwise @code{#f}.
|
|||
@node Objects
|
||||
@chapter Objects
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "entity?")
|
||||
@deffn primitive entity? obj
|
||||
Return @code{#t} if @var{obj} is an entity.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "operator?")
|
||||
@deffn primitive operator? obj
|
||||
Return @code{#t} if @var{obj} is an operator.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-object-procedure!")
|
||||
@deffn primitive set-object-procedure! obj proc
|
||||
Return the object procedure of @var{obj} to @var{proc}.
|
||||
@var{obj} must be either an entity or an operator.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-class-object")
|
||||
@deffn primitive make-class-object metaclass layout
|
||||
Create a new class object of class @var{metaclass}, with the
|
||||
slot layout specified by @var{layout}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-subclass-object")
|
||||
@deffn primitive make-subclass-object class layout
|
||||
Create a subclass object of @var{class}, with the slot layout
|
||||
specified by @var{layout}.
|
||||
|
|
|
@ -132,7 +132,6 @@ space use, and demonstrate how one would do Python's "from Tkinter
|
|||
import *" versus "import Tkinter". Must also add something about paths
|
||||
and standards for contributed modules.]
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "standard-eval-closure")
|
||||
@deffn primitive standard-eval-closure module
|
||||
Return an eval closure for the module @var{module}.
|
||||
@end deffn
|
||||
|
@ -182,7 +181,6 @@ written properly.
|
|||
Guile's dynamic linking functions make it relatively easy to write a
|
||||
module that incorporates code from third-party object code libraries.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-link")
|
||||
@deffn primitive dynamic-link filename
|
||||
Open the dynamic library called @var{filename}. A library
|
||||
handle representing the opened library is returned; this handle
|
||||
|
@ -190,13 +188,11 @@ should be used as the @var{dobj} argument to the following
|
|||
functions.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-object?")
|
||||
@deffn primitive dynamic-object? obj
|
||||
Return @code{#t} if @var{obj} is a dynamic library handle, or @code{#f}
|
||||
otherwise.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-unlink")
|
||||
@deffn primitive dynamic-unlink dobj
|
||||
Unlink the indicated object file from the application. The
|
||||
argument @var{dobj} must have been obtained by a call to
|
||||
|
@ -204,7 +200,6 @@ argument @var{dobj} must have been obtained by a call to
|
|||
called on @var{dobj}, its content is no longer accessible.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-func")
|
||||
@deffn primitive dynamic-func name dobj
|
||||
Search the dynamic object @var{dobj} for the C function
|
||||
indicated by the string @var{name} and return some Scheme
|
||||
|
@ -217,7 +212,6 @@ underscore in @var{function}. Guile knows whether the underscore is
|
|||
needed or not and will add it when necessary.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-call")
|
||||
@deffn primitive dynamic-call func dobj
|
||||
Call the C function indicated by @var{func} and @var{dobj}.
|
||||
The function is passed no arguments and its return value is
|
||||
|
@ -233,7 +227,6 @@ Interrupts are deferred while the C function is executing (with
|
|||
@code{SCM_DEFER_INTS}/@code{SCM_ALLOW_INTS}).
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-args-call")
|
||||
@deffn primitive dynamic-args-call func dobj args
|
||||
Call the C function indicated by @var{func} and @var{dobj},
|
||||
just like @code{dynamic-call}, but pass it some arguments and
|
||||
|
@ -250,7 +243,6 @@ converted to a Scheme number and returned from the call to
|
|||
@code{dynamic-args-call}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "c-registered-modules")
|
||||
@deffn primitive c-registered-modules
|
||||
Return a list of the object code modules that have been imported into
|
||||
the current Guile process. Each element of the list is a pair whose
|
||||
|
@ -259,7 +251,6 @@ for that module's initializer function. The name is the string that
|
|||
has been passed to scm_register_module_xxx.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "c-clear-registered-modules")
|
||||
@deffn primitive c-clear-registered-modules
|
||||
Destroy the list of modules registered with the current Guile process.
|
||||
The return value is unspecified. @strong{Warning:} this function does
|
||||
|
|
|
@ -275,9 +275,6 @@ It is often useful to have site-specific information about the current
|
|||
Guile installation. This chapter describes how to find out about
|
||||
Guile's configuration at run time.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "version")
|
||||
@c docstring begin (texi-doc-string "guile" "major-version")
|
||||
@c docstring begin (texi-doc-string "guile" "minor-version")
|
||||
@deffn primitive version
|
||||
@deffnx primitive major-version
|
||||
@deffnx primitive minor-version
|
||||
|
@ -299,26 +296,22 @@ interpreter and the ice-9 runtime have grown out of date with one
|
|||
another.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%package-data-dir")
|
||||
@deffn primitive %package-data-dir
|
||||
Return the name of the directory where Scheme packages, modules and
|
||||
libraries are kept. On most Unix systems, this will be
|
||||
@samp{/usr/local/share/guile}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%library-dir")
|
||||
@deffn primitive %library-dir
|
||||
Return the directory where the Guile Scheme library files are installed.
|
||||
E.g., may return "/usr/share/guile/1.3.5".
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%site-dir")
|
||||
@deffn primitive %site-dir
|
||||
Return the directory where the Guile site files are installed.
|
||||
E.g., may return "/usr/share/guile/site".
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "parse-path")
|
||||
@deffn primitive parse-path path [tail]
|
||||
Parse @var{path}, which is expected to be a colon-separated
|
||||
string, into a list and return the resulting list with
|
||||
|
@ -326,7 +319,6 @@ string, into a list and return the resulting list with
|
|||
is returned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "search-path")
|
||||
@deffn primitive search-path path filename [extensions]
|
||||
Search @var{path} for a directory containing a file named
|
||||
@var{filename}. The file must be readable, and not a directory.
|
||||
|
|
|
@ -22,28 +22,23 @@
|
|||
@node Procedure Properties
|
||||
@section Procedure Properties and Metainformation
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-properties")
|
||||
@deffn primitive procedure-properties proc
|
||||
Return @var{obj}'s property list.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-property")
|
||||
@deffn primitive procedure-property p k
|
||||
Return the property of @var{obj} with name @var{key}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-procedure-properties!")
|
||||
@deffn primitive set-procedure-properties! proc new_val
|
||||
Set @var{obj}'s property list to @var{alist}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-procedure-property!")
|
||||
@deffn primitive set-procedure-property! p k v
|
||||
In @var{obj}'s property list, set the property named @var{key} to
|
||||
@var{value}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-documentation")
|
||||
@deffn primitive procedure-documentation proc
|
||||
Return the documentation string associated with @code{proc}. By
|
||||
convention, if a procedure contains more than one expression and the
|
||||
|
@ -51,40 +46,33 @@ first expression is a string constant, that string is assumed to contain
|
|||
documentation for that procedure.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "closure?")
|
||||
@deffn primitive closure? obj
|
||||
Return @code{#t} if @var{obj} is a closure.
|
||||
@end deffn
|
||||
|
||||
@rnindex procedure?
|
||||
@c docstring begin (texi-doc-string "guile" "procedure?")
|
||||
@deffn primitive procedure? obj
|
||||
Return @code{#t} if @var{obj} is a procedure.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "thunk?")
|
||||
@deffn primitive thunk? obj
|
||||
Return @code{#t} if @var{obj} is a thunk.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-source-properties!")
|
||||
@deffn primitive set-source-properties! obj plist
|
||||
Install the association list @var{plist} as the source property
|
||||
list for @var{obj}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-source-property!")
|
||||
@deffn primitive set-source-property! obj key datum
|
||||
Set the source property of object @var{obj}, which is specified by
|
||||
@var{key} to @var{datum}. Normally, the key will be a symbol.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "source-properties")
|
||||
@deffn primitive source-properties obj
|
||||
Return the source property association list of @var{obj}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "source-property")
|
||||
|
||||
@deffn primitive source-property obj key
|
||||
Return the source property specified by @var{key} from
|
||||
|
@ -95,25 +83,21 @@ Return the source property specified by @var{key} from
|
|||
@node Procedures with Setters
|
||||
@section Procedures with Setters
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-procedure-with-setter")
|
||||
@deffn primitive make-procedure-with-setter procedure setter
|
||||
Create a new procedure which behaves like @var{procedure}, but
|
||||
with the associated setter @var{setter}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure-with-setter?")
|
||||
@deffn primitive procedure-with-setter? obj
|
||||
Return @code{#t} if @var{obj} is a procedure with an
|
||||
associated setter procedure.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure")
|
||||
@deffn primitive procedure proc
|
||||
Return the procedure of @var{proc}, which must be either a
|
||||
procedure with setter, or an operator struct.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "setter")
|
||||
@deffn primitive setter proc
|
||||
@end deffn
|
||||
|
||||
|
@ -126,7 +110,6 @@ macros and memoizing macros. Also, any definitions listed here should
|
|||
be double-checked by someone who knows what's going on. Ask Mikael, Jim
|
||||
or Aubrey for help. -twp]
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure->syntax")
|
||||
@deffn primitive procedure->syntax code
|
||||
Return a @dfn{macro} which, when a symbol defined to this value
|
||||
appears as the first symbol in an expression, returns the
|
||||
|
@ -134,7 +117,6 @@ result of applying @var{code} to the expression and the
|
|||
environment.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure->macro")
|
||||
@deffn primitive procedure->macro code
|
||||
Return a @dfn{macro} which, when a symbol defined to this value
|
||||
appears as the first symbol in an expression, evaluates the
|
||||
|
@ -151,7 +133,6 @@ passed to @var{code}. For example:
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "procedure->memoizing-macro")
|
||||
@deffn primitive procedure->memoizing-macro code
|
||||
Return a @dfn{macro} which, when a symbol defined to this value
|
||||
appears as the first symbol in an expression, evaluates the
|
||||
|
@ -168,13 +149,11 @@ passed to @var{proc}. For example:
|
|||
@end lisp
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "macro?")
|
||||
@deffn primitive macro? obj
|
||||
Return @code{#t} if @var{obj} is a regular macro, a memoizing macro or a
|
||||
syntax transformer.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "macro-type")
|
||||
@deffn primitive macro-type m
|
||||
Return one of the symbols @code{syntax}, @code{macro} or
|
||||
@code{macro!}, depending on whether @var{m} is a syntax
|
||||
|
@ -183,17 +162,14 @@ respectively. If @var{m} is not a macro, @code{#f} is
|
|||
returned.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "macro-name")
|
||||
@deffn primitive macro-name m
|
||||
Return the name of the macro @var{m}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "macro-transformer")
|
||||
@deffn primitive macro-transformer m
|
||||
Return the transformer of the macro @var{m}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "cons-source")
|
||||
@deffn primitive cons-source xorig x y
|
||||
Create and return a new pair whose car and cdr are @var{x} and @var{y}.
|
||||
Any source properties associated with @var{xorig} are also associated
|
||||
|
|
|
@ -18,20 +18,17 @@ reviewed and largely reorganized.]
|
|||
@node Arbiters
|
||||
@section Arbiters
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-arbiter")
|
||||
@deffn primitive make-arbiter name
|
||||
Return an object of type arbiter and name @var{name}. Its
|
||||
state is initially unlocked. Arbiters are a way to achieve
|
||||
process synchronization.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "try-arbiter")
|
||||
@deffn primitive try-arbiter arb
|
||||
Return @code{#t} and lock the arbiter @var{arb} if the arbiter
|
||||
was unlocked. Otherwise, return @code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "release-arbiter")
|
||||
@deffn primitive release-arbiter arb
|
||||
Return @code{#t} and unlock the arbiter @var{arb} if the
|
||||
arbiter was locked. Otherwise, return @code{#f}.
|
||||
|
@ -41,44 +38,36 @@ arbiter was locked. Otherwise, return @code{#f}.
|
|||
@node Asyncs
|
||||
@section Asyncs
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "async")
|
||||
@deffn primitive async thunk
|
||||
Create a new async for the procedure @var{thunk}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "system-async")
|
||||
@deffn primitive system-async thunk
|
||||
Create a new async for the procedure @var{thunk}. Also
|
||||
add it to the system's list of active async objects.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "async-mark")
|
||||
@deffn primitive async-mark a
|
||||
Mark the async @var{a} for future execution.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "system-async-mark")
|
||||
@deffn primitive system-async-mark a
|
||||
Mark the async @var{a} for future execution.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "run-asyncs")
|
||||
@deffn primitive run-asyncs list_of_a
|
||||
Execute all thunks from the asyncs of the list @var{list_of_a}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "noop")
|
||||
@deffn primitive noop . args
|
||||
Do nothing. When called without arguments, return @code{#f},
|
||||
otherwise return the first argument.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "unmask-signals")
|
||||
@deffn primitive unmask-signals
|
||||
Unmask signals. The returned value is not specified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "mask-signals")
|
||||
@deffn primitive mask-signals
|
||||
Mask signals. The returned value is not specified.
|
||||
@end deffn
|
||||
|
@ -104,7 +93,6 @@ dynamic root. For example, if you want to apply a procedure, but to
|
|||
not allow that procedure to capture the current continuation, calling
|
||||
the procedure under a new dynamic root will do the job.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "call-with-dynamic-root")
|
||||
@deffn primitive call-with-dynamic-root thunk handler
|
||||
Evaluate @code{(thunk)} in a new dynamic context, returning its value.
|
||||
|
||||
|
@ -151,7 +139,6 @@ be under a new dynamic root.)
|
|||
@end deffn
|
||||
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "dynamic-root")
|
||||
@deffn primitive dynamic-root
|
||||
Return an object representing the current dynamic root.
|
||||
|
||||
|
@ -293,7 +280,6 @@ Higher level thread procedures are available by loading the
|
|||
@code{(ice-9 threads)} module. These provide standardized
|
||||
thread creation and mutex interaction.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "%thread-handler")
|
||||
@deffn primitive %thread-handler tag args@dots{}
|
||||
|
||||
This procedure is specified as the standard error-handler for
|
||||
|
@ -308,27 +294,23 @@ and signals are unmasked with @code{unmask-signals}.
|
|||
[FIXME: Why distinguish based on number of args?! Cue voodoo music here.]
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-thread")
|
||||
@deffn macro make-thread proc [args@dots{}]
|
||||
Apply @var{proc} to @var{args} in a new thread formed by
|
||||
@code{call-with-new-thread} using @code{%thread-handler} as the error
|
||||
handler.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "begin-thread")
|
||||
@deffn macro begin-thread first [rest@dots{}]
|
||||
Evaluate forms @var{first} and @var{rest} in a new thread formed by
|
||||
@code{call-with-new-thread} using @code{%thread-handler} as the error
|
||||
handler.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "with-mutex")
|
||||
@deffn macro with-mutex m [body@dots{}]
|
||||
Lock mutex @var{m}, evaluate @var{body}, and then unlock @var{m}.
|
||||
These sub-operations form the branches of a @code{dynamic-wind}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "monitor")
|
||||
@deffn macro monitor first [rest@dots{}]
|
||||
Evaluate forms @var{first} and @var{rest} under a newly created
|
||||
anonymous mutex, using @code{with-mutex}.
|
||||
|
@ -340,7 +322,6 @@ anonymous mutex, using @code{with-mutex}.
|
|||
@node Fluids
|
||||
@section Fluids
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "make-fluid")
|
||||
@deffn primitive make-fluid
|
||||
Return a newly created fluid.
|
||||
Fluids are objects of a certain type (a smob) that can hold one SCM
|
||||
|
@ -351,25 +332,21 @@ inherits the values from its parent. Because each thread executes
|
|||
in its own dynamic root, you can use fluids for thread local storage.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fluid?")
|
||||
@deffn primitive fluid? obj
|
||||
Return @code{#t} iff @var{obj} is a fluid; otherwise, return
|
||||
@code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fluid-ref")
|
||||
@deffn primitive fluid-ref fluid
|
||||
Return the value associated with @var{fluid} in the current
|
||||
dynamic root. If @var{fluid} has not been set, then return
|
||||
@code{#f}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "fluid-set!")
|
||||
@deffn primitive fluid-set! fluid value
|
||||
Set the value associated with @var{fluid} in the current dynamic root.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "with-fluids*")
|
||||
@deffn primitive with-fluids* fluids values thunk
|
||||
Set @var{fluids} to @var{values} temporary, and call @var{thunk}.
|
||||
@var{fluids} must be a list of fluids and @var{values} must be the same
|
||||
|
|
|
@ -1,49 +0,0 @@
|
|||
@page
|
||||
@node Translation
|
||||
@chapter Support for Translating Other Languages
|
||||
|
||||
[Describe translation framework.]
|
||||
|
||||
@menu
|
||||
* Emacs Lisp Support:: Helper primitives for Emacs Lisp.
|
||||
@end menu
|
||||
|
||||
|
||||
@node Emacs Lisp Support
|
||||
@section Emacs Lisp Support
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "nil-car")
|
||||
@deffn primitive nil-car x
|
||||
Return the car of @var{x}, but convert it to LISP nil if it
|
||||
is Scheme's end-of-list.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "nil-cdr")
|
||||
@deffn primitive nil-cdr x
|
||||
Return the cdr of @var{x}, but convert it to LISP nil if it
|
||||
is Scheme's end-of-list.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "nil-cons")
|
||||
@deffn primitive nil-cons x y
|
||||
Create a new cons cell with @var{x} as the car and @var{y} as
|
||||
the cdr, but convert @var{y} to Scheme's end-of-list if it is
|
||||
a LISP nil.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "nil-eq")
|
||||
@deffn primitive nil-eq x y
|
||||
Compare @var{x} and @var{y} and return LISP's t if they are
|
||||
@code{eq?}, return LISP's nil otherwise.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "null")
|
||||
@deffn primitive null x
|
||||
Return LISP's @code{t} if @var{x} is nil in the LISP sense,
|
||||
return LISP's nil otherwise.
|
||||
@end deffn
|
||||
|
||||
|
||||
@c Local Variables:
|
||||
@c TeX-master: "guile.texi"
|
||||
@c End:
|
|
@ -15,7 +15,6 @@
|
|||
@section Equality
|
||||
|
||||
@rnindex eq?
|
||||
@c docstring begin (texi-doc-string "guile" "eq?")
|
||||
@deffn primitive eq? x y
|
||||
Return @code{#t} iff @var{x} references the same object as @var{y}.
|
||||
@code{eq?} is similar to @code{eqv?} except that in some cases it is
|
||||
|
@ -24,7 +23,6 @@ capable of discerning distinctions finer than those detectable by
|
|||
@end deffn
|
||||
|
||||
@rnindex eqv?
|
||||
@c docstring begin (texi-doc-string "guile" "eqv?")
|
||||
@deffn primitive eqv? x y
|
||||
The @code{eqv?} procedure defines a useful equivalence relation on objects.
|
||||
Briefly, it returns @code{#t} if @var{x} and @var{y} should normally be
|
||||
|
@ -34,7 +32,6 @@ and inexact numbers.
|
|||
@end deffn
|
||||
|
||||
@rnindex equal?
|
||||
@c docstring begin (texi-doc-string "guile" "equal?")
|
||||
@deffn primitive equal? x y
|
||||
Return @code{#t} iff @var{x} and @var{y} are recursively @code{eqv?} equivalent.
|
||||
@code{equal?} recursively compares the contents of pairs,
|
||||
|
@ -60,25 +57,21 @@ closures than for other kinds of objects. Therefore, when manipulating
|
|||
a property list associated with a procedure object, use the
|
||||
@code{procedure} functions; otherwise, use the @code{object} functions.
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "object-properties")
|
||||
@deffn primitive object-properties obj
|
||||
@deffnx primitive procedure-properties obj
|
||||
Return @var{obj}'s property list.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-object-properties!")
|
||||
@deffn primitive set-object-properties! obj alist
|
||||
@deffnx primitive set-procedure-properties! obj alist
|
||||
Set @var{obj}'s property list to @var{alist}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "object-property")
|
||||
@deffn primitive object-property obj key
|
||||
@deffnx primitive procedure-property obj key
|
||||
Return the property of @var{obj} with name @var{key}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "set-object-property!")
|
||||
@deffn primitive set-object-property! obj key value
|
||||
@deffnx primitive set-procedure-property! obj key value
|
||||
In @var{obj}'s property list, set the property named @var{key}
|
||||
|
@ -92,7 +85,6 @@ the user provides a "property table" that is possibly private.]
|
|||
@node Primitive Properties
|
||||
@section Primitive Properties
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-make-property")
|
||||
@deffn primitive primitive-make-property not_found_proc
|
||||
Create a @dfn{property token} that can be used with
|
||||
@code{primitive-property-ref} and @code{primitive-property-set!}.
|
||||
|
@ -100,7 +92,6 @@ See @code{primitive-property-ref} for the significance of
|
|||
@var{not_found_proc}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-property-ref")
|
||||
@deffn primitive primitive-property-ref prop obj
|
||||
Return the property @var{prop} of @var{obj}. When no value
|
||||
has yet been associated with @var{prop} and @var{obj}, call
|
||||
|
@ -111,12 +102,10 @@ and use its return value. That value is also associated with
|
|||
default value of @var{prop}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-property-set!")
|
||||
@deffn primitive primitive-property-set! prop obj val
|
||||
Associate @var{code} with @var{prop} and @var{obj}.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "primitive-property-del!")
|
||||
@deffn primitive primitive-property-del! prop obj
|
||||
Remove any value associated with @var{prop} and @var{obj}.
|
||||
@end deffn
|
||||
|
@ -125,7 +114,6 @@ Remove any value associated with @var{prop} and @var{obj}.
|
|||
@node Sorting
|
||||
@section Sorting
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "merge!")
|
||||
@deffn primitive merge! alist blist less
|
||||
Takes two lists @var{alist} and @var{blist} such that
|
||||
@code{(sorted? alist less?)} and @code{(sorted? blist less?)} and
|
||||
|
@ -136,11 +124,9 @@ This is the destructive variant of @code{merge}
|
|||
Note: this does _not_ accept vectors.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "merge")
|
||||
@deffn primitive merge alist blist less
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "restricted-vector-sort!")
|
||||
@deffn primitive restricted-vector-sort! vec less startpos endpos
|
||||
Sort the vector @var{vec}, using @var{less} for comparing
|
||||
the vector elements. @var{startpos} and @var{endpos} delimit
|
||||
|
@ -148,7 +134,6 @@ the range of the vector which gets sorted. The return value
|
|||
is not specified.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sort!")
|
||||
@deffn primitive sort! items less
|
||||
Sort the sequence @var{items}, which may be a list or a
|
||||
vector. @var{less} is used for comparing the sequence
|
||||
|
@ -157,14 +142,12 @@ input sequence is modified to produce the sorted result.
|
|||
This is not a stable sort.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sort")
|
||||
@deffn primitive sort items less
|
||||
Sort the sequence @var{items}, which may be a list or a
|
||||
vector. @var{less} is used for comparing the sequence
|
||||
elements. This is not a stable sort.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sort-list!")
|
||||
@deffn primitive sort-list! items less
|
||||
Sort the list @var{items}, using @var{less} for comparing the
|
||||
list elements. The sorting is destructive, that means that the
|
||||
|
@ -172,20 +155,17 @@ input list is modified to produce the sorted result.
|
|||
This is a stable sort.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sort-list")
|
||||
@deffn primitive sort-list items less
|
||||
Sort the list @var{items}, using @var{less} for comparing the
|
||||
list elements. This is a stable sort.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "sorted?")
|
||||
@deffn primitive sorted? items less
|
||||
Return @code{#t} iff @var{items} is a list or a vector such that
|
||||
for all 1 <= i <= m, the predicate @var{less} returns true when
|
||||
applied to all elements i - 1 and i
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "stable-sort!")
|
||||
@deffn primitive stable-sort! items less
|
||||
Sort the sequence @var{items}, which may be a list or a
|
||||
vector. @var{less} is used for comparing the sequence elements.
|
||||
|
@ -194,7 +174,6 @@ is modified to produce the sorted result.
|
|||
This is a stable sort.
|
||||
@end deffn
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "stable-sort")
|
||||
@deffn primitive stable-sort items less
|
||||
Sort the sequence @var{items}, which may be a list or a
|
||||
vector. @var{less} is used for comparing the sequence elements.
|
||||
|
@ -205,7 +184,6 @@ This is a stable sort.
|
|||
@node Copying
|
||||
@section Copying Deep Structures
|
||||
|
||||
@c docstring begin (texi-doc-string "guile" "copy-tree")
|
||||
@deffn primitive copy-tree obj
|
||||
Recursively copy the data tree that is bound to @var{obj}, and return a
|
||||
pointer to the new data structure. @code{copy-tree} recurses down the
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue