summaryrefslogtreecommitdiffstats
path: root/byte.txi
diff options
context:
space:
mode:
authorThomas Bushnell, BSG <tb@debian.org>2005-11-02 14:55:21 -0800
committerBryan Newbold <bnewbold@robocracy.org>2017-02-20 00:05:32 -0800
commit34c54a22ff7818bb8b38ef4d9c87dbbcb221ba73 (patch)
tree1189d06a81277bcf8539b0260a69a19f6038effb /byte.txi
parent611b3db17894e5fdc0db3d49eaf6743d27b44233 (diff)
parent5145dd3aa0c02c9fc496d1432fc4410674206e1d (diff)
downloadslib-34c54a22ff7818bb8b38ef4d9c87dbbcb221ba73.tar.gz
slib-34c54a22ff7818bb8b38ef4d9c87dbbcb221ba73.zip
Import Debian changes 3a2-1debian/3a2-1
slib (3a2-1) unstable; urgency=low * New upstream release. * Acknowledge NMU. (Closes: #281809) * Makefile: Don't hack Makefile; use rules instead. * debian/rules: Set on make invocations: prefix, htmldir, TEXI2HTML. * debian/rules (clean): Clean more stuff here. * Makefile: Comment out old rule for $(htmldir)slib_toc.html. Instead, specify directly that the texi2html invocation produces that file. * debian/rules (binary-indep): Find web files in slib subdir. * debian/control (Build-Depends-Indep): Go back to using scm.
Diffstat (limited to 'byte.txi')
-rw-r--r--byte.txi16
1 files changed, 16 insertions, 0 deletions
diff --git a/byte.txi b/byte.txi
index 01c725b..e4502b9 100644
--- a/byte.txi
+++ b/byte.txi
@@ -16,6 +16,7 @@ character sets. These functions abstract the notion of a @dfn{byte}.
zero-origin indexing.
@end defun
+
@deffn {Procedure} byte-set! bytes k byte
@var{k} must be a valid index of @var{bytes}, and @var{byte} must be a small
@@ -23,6 +24,7 @@ nonnegative integer. @code{byte-set!} stores @var{byte} in element @var{k} of @
returns an unspecified value. @c <!>
@end deffn
+
@defun make-bytes k byte
@@ -32,28 +34,33 @@ given, then all elements of the byte-array are initialized to @var{byte},
otherwise the contents of the byte-array are unspecified.
@end defun
+
@defun bytes-length bytes
@code{bytes-length} returns length of byte-array @var{bytes}.
@end defun
+
@defun bytes byte @dots{}
Returns a newly allocated byte-array composed of the small
nonnegative arguments.
@end defun
+
@defun bytes->list bytes
@code{bytes->list} returns a newly allocated list of the bytes that make up the
given byte-array.
@end defun
+
@defun list->bytes bytes
@code{list->bytes} returns a newly allocated byte-array formed from the small
nonnegative integers in the list @var{bytes}.
@end defun
+
@noindent
@code{Bytes->list} and @code{list->bytes} are inverses so far as
@code{equal?} is concerned.
@@ -65,16 +72,19 @@ nonnegative integers in the list @var{bytes}.
Returns a newly allocated copy of the given @var{bytes}.
@end defun
+
@deffn {Procedure} bytes-reverse! bytes
Reverses the order of byte-array @var{bytes}.
@end deffn
+
@defun bytes-reverse bytes
Returns a newly allocated bytes-array consisting of the elements of
@var{bytes} in reverse order.
@end defun
+
@noindent
@cindex binary
Input and output of bytes should be with ports opened in @dfn{binary}
@@ -96,6 +106,7 @@ be omitted, in which case it defaults to the value returned by
@findex current-output-port
@end defun
+
@defun read-byte port
@@ -106,6 +117,7 @@ end-of-file object is returned. @var{port} may be omitted, in which case it
defaults to the value returned by @code{current-input-port}.
@findex current-input-port
@end defun
+
@noindent
When reading and writing binary numbers with @code{read-bytes} and
@code{write-bytes}, the sign of the length argument determines the
@@ -135,6 +147,7 @@ end-of-file.
by @code{current-input-port}.
@end defun
+
@defun write-bytes bytes n port
@@ -147,6 +160,7 @@ value.
@var{port} may be omitted, in which case it defaults to the value returned
by @code{current-output-port}.
@end defun
+
@noindent
@code{substring-read!} and @code{substring-write} provide
lower-level procedures for reading and writing blocks of bytes. The
@@ -166,6 +180,7 @@ read from @var{port}. The first byte read is stored at index @var{string}.
by @code{current-input-port}.
@end deffn
+
@defun substring-write string start end port
@@ -177,3 +192,4 @@ returns the number of bytes written.
@var{port} may be omitted, in which case it defaults to the value returned
by @code{current-output-port}.
@end defun
+