1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-20 11:40:18 +02:00

Clarifications from Ludovic Courtès. Thanks!

This commit is contained in:
Marius Vollmer 2005-05-22 18:03:03 +00:00
parent 188d0c5ef7
commit d34bd7d483

View file

@ -895,11 +895,14 @@ handle mustr eventually be released with
@code{scm_array_handle_release}. @code{scm_array_handle_release}.
The variables pointed to by @var{lenp} and @var{incp} are filled with The variables pointed to by @var{lenp} and @var{incp} are filled with
the number of elements of the vector and the increment between elements, the number of elements of the vector and the increment (number of
respectively. Note that the increment can well be negative. elements) between successive elements, respectively. Successive
elements of @var{vec} need not be contiguous in their underlying
``root vector'' returned here; hence the increment is not necessarily
equal to 1 and may well be negative too (@pxref{Shared Arrays}).
The following example shows the typical way to use this function. It The following example shows the typical way to use this function. It
creates a list of all elements of @code{vec} (in reverse order). creates a list of all elements of @var{vec} (in reverse order).
@example @example
scm_t_array_handle handle; scm_t_array_handle handle;
@ -1362,8 +1365,9 @@ Return the number of elements of @var{uvec} as a @code{size_t}.
@deftypefnx {C Function} {const double *} scm_f64vector_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefnx {C Function} {const double *} scm_f64vector_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
@deftypefnx {C Function} {const float *} scm_c32vector_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefnx {C Function} {const float *} scm_c32vector_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
@deftypefnx {C Function} {const double *} scm_c64vector_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefnx {C Function} {const double *} scm_c64vector_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
Like @code{scm_vector_elements} (which see), but returns a pointer to Like @code{scm_vector_elements} (@pxref{Vector Accessing from C}), but
the elements of a uniform numeric vector of the indicated kind. returns a pointer to the elements of a uniform numeric vector of the
indicated kind.
@end deftypefn @end deftypefn
@deftypefn {C Function} {void *} scm_uniform_vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefn {C Function} {void *} scm_uniform_vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
@ -1379,8 +1383,9 @@ the elements of a uniform numeric vector of the indicated kind.
@deftypefnx {C Function} {double *} scm_f64vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefnx {C Function} {double *} scm_f64vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
@deftypefnx {C Function} {float *} scm_c32vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefnx {C Function} {float *} scm_c32vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
@deftypefnx {C Function} {double *} scm_c64vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp) @deftypefnx {C Function} {double *} scm_c64vector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *lenp, ssize_t *incp)
Like @code{scm_vector_writable_elements} (which see), but returns a Like @code{scm_vector_writable_elements} (@pxref{Vector Accessing from
pointer to the elements of a uniform numeric vector of the indicated kind. C}), but returns a pointer to the elements of a uniform numeric vector
of the indicated kind.
@end deftypefn @end deftypefn
@deffn {Scheme Procedure} uniform-vector-read! uvec [port_or_fd [start [end]]] @deffn {Scheme Procedure} uniform-vector-read! uvec [port_or_fd [start [end]]]
@ -1605,11 +1610,11 @@ For example,
@end deffn @end deffn
@deftypefn {C Function} {const scm_t_uint32 *} scm_bitvector_elements (SCM vec, scm_t_array_handle *handle, size_t *offp, size_t *lenp, ssize_t *incp) @deftypefn {C Function} {const scm_t_uint32 *} scm_bitvector_elements (SCM vec, scm_t_array_handle *handle, size_t *offp, size_t *lenp, ssize_t *incp)
Like @code{scm_vector_elements} (which see), but for bitvectors. The Like @code{scm_vector_elements} (@pxref{Vector Accessing from C}), but
variable pointed to by @var{offp} is set to the value returned by for bitvectors. The variable pointed to by @var{offp} is set to the
@code{scm_array_handle_bit_elements_offset}. See value returned by @code{scm_array_handle_bit_elements_offset}. See
@code{scm_array_handle_bit_elements} for how to use the returned pointer @code{scm_array_handle_bit_elements} for how to use the returned
and the offset. pointer and the offset.
@end deftypefn @end deftypefn
@deftypefn {C Function} {scm_t_uint32 *} scm_bitvector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *offp, size_t *lenp, ssize_t *incp) @deftypefn {C Function} {scm_t_uint32 *} scm_bitvector_writable_elements (SCM vec, scm_t_array_handle *handle, size_t *offp, size_t *lenp, ssize_t *incp)