diff options
author | Andy Wingo <wingo@pobox.com> | 2012-07-06 16:52:54 +0200 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2012-07-06 16:52:54 +0200 |
commit | 2aed2667fce5ccb115667a36ffd368c4c3b6e9f4 (patch) | |
tree | 21c31f62bca976076b851d01104327152035e8d4 /doc/ref/api-control.texi | |
parent | b8bc86bce147cf280ca2a60d36c8b6493cbf11e8 (diff) | |
parent | 24dd9f6fe1449fa4de81d95ca659283c15e16931 (diff) | |
download | guile-2aed2667fce5ccb115667a36ffd368c4c3b6e9f4.tar.gz |
Merge remote-tracking branch 'origin/stable-2.0'
Conflicts:
libguile/expand.c
libguile/hashtab.c
libguile/ports.c
libguile/vectors.c
libguile/weaks.c
module/language/ecmascript/compile-tree-il.scm
module/language/tree-il/effects.scm
module/language/tree-il/fix-letrec.scm
module/language/tree-il/peval.scm
test-suite/tests/peval.test
Diffstat (limited to 'doc/ref/api-control.texi')
-rw-r--r-- | doc/ref/api-control.texi | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/doc/ref/api-control.texi b/doc/ref/api-control.texi index 6eac8726f..d8b6a45ad 100644 --- a/doc/ref/api-control.texi +++ b/doc/ref/api-control.texi @@ -841,12 +841,27 @@ the current implementation that object shares structure with @var{args}, so @var{args} should not be modified subsequently. @end deffn -@deffn {C Function} scm_c_value_ref (values, idx) +@deftypefn {C Function} SCM scm_c_values (SCM *base, size_t n) +@code{scm_c_values} is an alternative to @code{scm_values}. It creates +a new values object, and copies into it the @var{n} values starting from +@var{base}. + +Currently this creates a list and passes it to @code{scm_values}, but we +expect that in the future we will be able to use more a efficient +representation. +@end deftypefn + +@deftypefn {C Function} size_t scm_c_nvalues (SCM obj) +If @var{obj} is a multiple-values object, returns the number of values +it contains. Otherwise returns 1. +@end deftypefn + +@deftypefn {C Function} SCM scm_c_value_ref (SCM obj, size_t idx) Returns the value at the position specified by @var{idx} in -@var{values}. Note that @var{values} will ordinarily be a +@var{obj}. Note that @var{obj} will ordinarily be a multiple-values object, but it need not be. Any other object represents a single value (itself), and is handled appropriately. -@end deffn +@end deftypefn @rnindex call-with-values @deffn {Scheme Procedure} call-with-values producer consumer |