]> git.donarmstrong.com Git - lilypond.git/blob - guile18/doc/ref/api-undocumented.texi
New upstream version 2.19.65
[lilypond.git] / guile18 / doc / ref / api-undocumented.texi
1 This file gathers entries that have been automatically generated from
2 docstrings in libguile.  They are not included in the manual, however,
3 for various reasons, mostly because they have been deprecated.  They
4 are here in this file to give docstring.el a chance to update them
5 automatically.
6
7 - The 'environments' are only in Guile by accident and are not used at
8   all and we don't want to advertise them.
9
10 - GOOPS is documented in its own manual.
11
12
13
14 @deffn {Scheme Procedure} substring-move-right!
15 implemented by the C function "scm_substring_move_x"
16 @end deffn
17
18 @deffn {Scheme Procedure} substring-move-left!
19 implemented by the C function "scm_substring_move_x"
20 @end deffn
21
22 @deffn {Scheme Procedure} gentemp [prefix [obarray]]
23 @deffnx {C Function} scm_gentemp (prefix, obarray)
24 Create a new symbol with a name unique in an obarray.
25 The name is constructed from an optional string @var{prefix}
26 and a counter value.  The default prefix is @code{t}.  The
27 @var{obarray} is specified as a second optional argument.
28 Default is the system obarray where all normal symbols are
29 interned.  The counter is increased by 1 at each
30 call.  There is no provision for resetting the counter.
31 @end deffn
32
33 @deffn {Scheme Procedure} symbol-set! o s v
34 @deffnx {C Function} scm_symbol_set_x (o, s, v)
35 Find the symbol in @var{obarray} whose name is @var{string}, and rebind
36 it to @var{value}.  An error is signalled if @var{string} is not present
37 in @var{obarray}.
38 @end deffn
39
40 @deffn {Scheme Procedure} symbol-bound? o s
41 @deffnx {C Function} scm_symbol_bound_p (o, s)
42 Return @code{#t} if @var{obarray} contains a symbol with name
43 @var{string} bound to a defined value.  This differs from
44 @var{symbol-interned?} in that the mere mention of a symbol
45 usually causes it to be interned; @code{symbol-bound?}
46 determines whether a symbol has been given any meaningful
47 value.
48 @end deffn
49
50 @deffn {Scheme Procedure} symbol-binding o s
51 @deffnx {C Function} scm_symbol_binding (o, s)
52 Look up in @var{obarray} the symbol whose name is @var{string}, and
53 return the value to which it is bound.  If @var{obarray} is @code{#f},
54 use the global symbol table.  If @var{string} is not interned in
55 @var{obarray}, an error is signalled.
56 @end deffn
57
58 @deffn {Scheme Procedure} unintern-symbol o s
59 @deffnx {C Function} scm_unintern_symbol (o, s)
60 Remove the symbol with name @var{string} from @var{obarray}.  This
61 function returns @code{#t} if the symbol was present and @code{#f}
62 otherwise.
63 @end deffn
64
65 @deffn {Scheme Procedure} intern-symbol o s
66 @deffnx {C Function} scm_intern_symbol (o, s)
67 Add a new symbol to @var{obarray} with name @var{string}, bound to an
68 unspecified initial value.  The symbol table is not modified if a symbol
69 with this name is already present.
70 @end deffn
71
72 @deffn {Scheme Procedure} string->obarray-symbol o s [softp]
73 @deffnx {C Function} scm_string_to_obarray_symbol (o, s, softp)
74 Intern a new symbol in @var{obarray}, a symbol table, with name
75 @var{string}.
76
77 If @var{obarray} is @code{#f}, use the default system symbol table.  If
78 @var{obarray} is @code{#t}, the symbol should not be interned in any
79 symbol table; merely return the pair (@var{symbol}
80 . @var{#<undefined>}).
81
82 The @var{soft?} argument determines whether new symbol table entries
83 should be created when the specified symbol is not already present in
84 @var{obarray}.  If @var{soft?} is specified and is a true value, then
85 new entries should not be added for symbols not already present in the
86 table; instead, simply return @code{#f}.
87 @end deffn
88
89 @deffn {Scheme Procedure} read-and-eval! [port]
90 @deffnx {C Function} scm_read_and_eval_x (port)
91 Read a form from @var{port} (standard input by default), and evaluate it
92 (memoizing it in the process) in the top-level environment.  If no data
93 is left to be read from @var{port}, an @code{end-of-file} error is
94 signalled.
95 @end deffn
96
97 @deffn {Scheme Procedure} sloppy-member x lst
98 @deffnx {C Function} scm_sloppy_member (x, lst)
99 This procedure behaves like @code{member}, but does no type or error checking.
100 Its use is recommended only in writing Guile internals,
101 not for high-level Scheme programs.
102 @end deffn
103
104 @deffn {Scheme Procedure} sloppy-memv x lst
105 @deffnx {C Function} scm_sloppy_memv (x, lst)
106 This procedure behaves like @code{memv}, but does no type or error checking.
107 Its use is recommended only in writing Guile internals,
108 not for high-level Scheme programs.
109 @end deffn
110
111 @deffn {Scheme Procedure} sloppy-memq x lst
112 @deffnx {C Function} scm_sloppy_memq (x, lst)
113 This procedure behaves like @code{memq}, but does no type or error checking.
114 Its use is recommended only in writing Guile internals,
115 not for high-level Scheme programs.
116 @end deffn
117
118 @deffn {Scheme Procedure} builtin-variable name
119 @deffnx {C Function} scm_builtin_variable (name)
120 Do not use this function.
121 @end deffn
122
123 @deffn {Scheme Procedure} variable-set-name-hint! var hint
124 @deffnx {C Function} scm_variable_set_name_hint (var, hint)
125 Do not use this function.
126 @end deffn
127
128 @deffn {Scheme Procedure} close-all-ports-except . ports
129 @deffnx {C Function} scm_close_all_ports_except (ports)
130 [DEPRECATED] Close all open file ports used by the interpreter
131 except for those supplied as arguments.  This procedure
132 was intended to be used before an exec call to close file descriptors
133 which are not needed in the new process.  However it has the
134 undesirable side effect of flushing buffers, so it's deprecated.
135 Use port-for-each instead.
136 @end deffn
137
138 @deffn {Scheme Procedure} c-clear-registered-modules
139 @deffnx {C Function} scm_clear_registered_modules ()
140 Destroy the list of modules registered with the current Guile process.
141 The return value is unspecified.  @strong{Warning:} this function does
142 not actually unlink or deallocate these modules, but only destroys the
143 records of which modules have been loaded.  It should therefore be used
144 only by module bookkeeping operations.
145 @end deffn
146
147 @deffn {Scheme Procedure} c-registered-modules
148 @deffnx {C Function} scm_registered_modules ()
149 Return a list of the object code modules that have been imported into
150 the current Guile process.  Each element of the list is a pair whose
151 car is the name of the module, and whose cdr is the function handle
152 for that module's initializer function.  The name is the string that
153 has been passed to scm_register_module_xxx.
154 @end deffn
155
156 @deffn {Scheme Procedure} module-import-interface module sym
157 @deffnx {C Function} scm_module_import_interface (module, sym)
158
159 @end deffn
160
161
162 @deffn {Scheme Procedure} self-evaluating? obj
163 @deffnx {C Function} scm_self_evaluating_p (obj)
164 Return #t for objects which Guile considers self-evaluating
165 @end deffn
166
167 @deffn {Scheme Procedure} unmemoize-expr m
168 @deffnx {C Function} scm_i_unmemoize_expr (m)
169 Unmemoize the memoized expression @var{m},
170 @end deffn
171
172 @deffn {Scheme Procedure} weak-key-alist-vector? obj
173 @deffnx {Scheme Procedure} weak-value-alist-vector? obj
174 @deffnx {Scheme Procedure} doubly-weak-alist-vector? obj
175 @deffnx {C Function} scm_weak_key_alist_vector_p (obj)
176 Return @code{#t} if @var{obj} is the specified weak hash
177 table. Note that a doubly weak hash table is neither a weak key
178 nor a weak value hash table.
179 @end deffn
180
181 @deffn {Scheme Procedure} make-weak-key-alist-vector [size]
182 @deffnx {Scheme Procedure} make-weak-value-alist-vector size
183 @deffnx {Scheme Procedure} make-doubly-weak-alist-vector size
184 @deffnx {C Function} scm_make_weak_key_alist_vector (size)
185 Return a weak hash table with @var{size} buckets. As with any
186 hash table, choosing a good size for the table requires some
187 caution.
188
189 You can modify weak hash tables in exactly the same way you
190 would modify regular hash tables. (@pxref{Hash Tables})
191 @end deffn
192
193 @deffn {Scheme Procedure} include-deprecated-features
194 Return @code{#t} iff deprecated features should be included
195 in public interfaces.
196 @end deffn
197
198 @deffn {Scheme Procedure} issue-deprecation-warning . msgs
199 Output @var{msgs} to @code{(current-error-port)} when this
200 is the first call to @code{issue-deprecation-warning} with
201 this specific @var{msg}.  Do nothing otherwise.
202 The argument @var{msgs} should be a list of strings;
203 they are printed in turn, each one followed by a newline.
204 @end deffn
205
206 @deffn {Scheme Procedure} valid-object-procedure? proc
207 @deffnx {C Function} scm_valid_object_procedure_p (proc)
208 Return @code{#t} iff @var{proc} is a procedure that can be used with @code{set-object-procedure}.  It is always valid to use a closure constructed by @code{lambda}.
209 @end deffn
210
211 @deffn {Scheme Procedure} %get-pre-modules-obarray
212 @deffnx {C Function} scm_get_pre_modules_obarray ()
213 Return the obarray that is used for all new bindings before the module system is booted.  The first call to @code{set-current-module} will boot the module system.
214 @end deffn
215
216 @deffn {Scheme Procedure} standard-interface-eval-closure module
217 @deffnx {C Function} scm_standard_interface_eval_closure (module)
218 Return a interface eval closure for the module @var{module}. Such a closure does not allow new bindings to be added.
219 @end deffn
220
221 @deffn {Scheme Procedure} env-module env
222 @deffnx {C Function} scm_env_module (env)
223 Return the module of @var{ENV}, a lexical environment.
224 @end deffn
225
226 @deffn {Scheme Procedure} single-active-thread?
227 implemented by the C function "scm_single_thread_p"
228 @end deffn
229
230 @deffn {Scheme Procedure} set-debug-cell-accesses! flag
231 @deffnx {C Function} scm_set_debug_cell_accesses_x (flag)
232 This function is used to turn on checking for a debug version of GUILE. This version does not support this functionality
233
234 @end deffn
235
236 @deffn {Scheme Procedure} standard-eval-closure module
237 @deffnx {C Function} scm_standard_eval_closure (module)
238 Return an eval closure for the module @var{module}.
239 @end deffn
240
241 @deffn {Scheme Procedure} mask-signals
242 @deffnx {C Function} scm_mask_signals ()
243 Mask signals. The returned value is not specified.
244 @end deffn
245
246 @deffn {Scheme Procedure} unmask-signals
247 @deffnx {C Function} scm_unmask_signals ()
248 Unmask signals. The returned value is not specified.
249 @end deffn
250
251 @deffn {Scheme Procedure} noop . args
252 @deffnx {C Function} scm_noop (args)
253 Do nothing.  When called without arguments, return @code{#f},
254 otherwise return the first argument.
255 @end deffn
256
257 @deffn {Scheme Procedure} system-async thunk
258 @deffnx {C Function} scm_system_async (thunk)
259 This function is deprecated.  You can use @var{thunk} directly
260 instead of explicitly creating an async object.
261
262 @end deffn
263
264 @deffn {Scheme Procedure} object-address obj
265 @deffnx {C Function} scm_object_address (obj)
266 Return an integer that for the lifetime of @var{obj} is uniquely
267 returned by this function for @var{obj}
268 @end deffn
269
270 @deffn {Scheme Procedure} environment? obj
271 @deffnx {C Function} scm_environment_p (obj)
272 Return @code{#t} if @var{obj} is an environment, or @code{#f}
273 otherwise.
274 @end deffn
275
276 @deffn {Scheme Procedure} environment-bound? env sym
277 @deffnx {C Function} scm_environment_bound_p (env, sym)
278 Return @code{#t} if @var{sym} is bound in @var{env}, or
279 @code{#f} otherwise.
280 @end deffn
281
282 @deffn {Scheme Procedure} environment-ref env sym
283 @deffnx {C Function} scm_environment_ref (env, sym)
284 Return the value of the location bound to @var{sym} in
285 @var{env}. If @var{sym} is unbound in @var{env}, signal an
286 @code{environment:unbound} error.
287 @end deffn
288
289 @deffn {Scheme Procedure} environment-fold env proc init
290 @deffnx {C Function} scm_environment_fold (env, proc, init)
291 Iterate over all the bindings in @var{env}, accumulating some
292 value.
293 For each binding in @var{env}, apply @var{proc} to the symbol
294 bound, its value, and the result from the previous application
295 of @var{proc}.
296 Use @var{init} as @var{proc}'s third argument the first time
297 @var{proc} is applied.
298 If @var{env} contains no bindings, this function simply returns
299 @var{init}.
300 If @var{env} binds the symbol sym1 to the value val1, sym2 to
301 val2, and so on, then this procedure computes:
302 @lisp
303   (proc sym1 val1
304         (proc sym2 val2
305               ...
306               (proc symn valn
307                     init)))
308 @end lisp
309 Each binding in @var{env} will be processed exactly once.
310 @code{environment-fold} makes no guarantees about the order in
311 which the bindings are processed.
312 Here is a function which, given an environment, constructs an
313 association list representing that environment's bindings,
314 using environment-fold:
315 @lisp
316   (define (environment->alist env)
317     (environment-fold env
318                       (lambda (sym val tail)
319                         (cons (cons sym val) tail))
320                       '()))
321 @end lisp
322 @end deffn
323
324 @deffn {Scheme Procedure} environment-define env sym val
325 @deffnx {C Function} scm_environment_define (env, sym, val)
326 Bind @var{sym} to a new location containing @var{val} in
327 @var{env}. If @var{sym} is already bound to another location
328 in @var{env} and the binding is mutable, that binding is
329 replaced.  The new binding and location are both mutable. The
330 return value is unspecified.
331 If @var{sym} is already bound in @var{env}, and the binding is
332 immutable, signal an @code{environment:immutable-binding} error.
333 @end deffn
334
335 @deffn {Scheme Procedure} environment-undefine env sym
336 @deffnx {C Function} scm_environment_undefine (env, sym)
337 Remove any binding for @var{sym} from @var{env}. If @var{sym}
338 is unbound in @var{env}, do nothing.  The return value is
339 unspecified.
340 If @var{sym} is already bound in @var{env}, and the binding is
341 immutable, signal an @code{environment:immutable-binding} error.
342 @end deffn
343
344 @deffn {Scheme Procedure} environment-set! env sym val
345 @deffnx {C Function} scm_environment_set_x (env, sym, val)
346 If @var{env} binds @var{sym} to some location, change that
347 location's value to @var{val}.  The return value is
348 unspecified.
349 If @var{sym} is not bound in @var{env}, signal an
350 @code{environment:unbound} error.  If @var{env} binds @var{sym}
351 to an immutable location, signal an
352 @code{environment:immutable-location} error.
353 @end deffn
354
355 @deffn {Scheme Procedure} environment-cell env sym for_write
356 @deffnx {C Function} scm_environment_cell (env, sym, for_write)
357 Return the value cell which @var{env} binds to @var{sym}, or
358 @code{#f} if the binding does not live in a value cell.
359 The argument @var{for-write} indicates whether the caller
360 intends to modify the variable's value by mutating the value
361 cell.  If the variable is immutable, then
362 @code{environment-cell} signals an
363 @code{environment:immutable-location} error.
364 If @var{sym} is unbound in @var{env}, signal an
365 @code{environment:unbound} error.
366 If you use this function, you should consider using
367 @code{environment-observe}, to be notified when @var{sym} gets
368 re-bound to a new value cell, or becomes undefined.
369 @end deffn
370
371 @deffn {Scheme Procedure} environment-observe env proc
372 @deffnx {C Function} scm_environment_observe (env, proc)
373 Whenever @var{env}'s bindings change, apply @var{proc} to
374 @var{env}.
375 This function returns an object, token, which you can pass to
376 @code{environment-unobserve} to remove @var{proc} from the set
377 of procedures observing @var{env}.  The type and value of
378 token is unspecified.
379 @end deffn
380
381 @deffn {Scheme Procedure} environment-observe-weak env proc
382 @deffnx {C Function} scm_environment_observe_weak (env, proc)
383 This function is the same as environment-observe, except that
384 the reference @var{env} retains to @var{proc} is a weak
385 reference. This means that, if there are no other live,
386 non-weak references to @var{proc}, it will be
387 garbage-collected, and dropped from @var{env}'s
388 list of observing procedures.
389 @end deffn
390
391 @deffn {Scheme Procedure} environment-unobserve token
392 @deffnx {C Function} scm_environment_unobserve (token)
393 Cancel the observation request which returned the value
394 @var{token}.  The return value is unspecified.
395 If a call @code{(environment-observe env proc)} returns
396 @var{token}, then the call @code{(environment-unobserve token)}
397 will cause @var{proc} to no longer be called when @var{env}'s
398 bindings change.
399 @end deffn
400
401 @deffn {Scheme Procedure} make-leaf-environment
402 @deffnx {C Function} scm_make_leaf_environment ()
403 Create a new leaf environment, containing no bindings.
404 All bindings and locations created in the new environment
405 will be mutable.
406 @end deffn
407
408 @deffn {Scheme Procedure} leaf-environment? object
409 @deffnx {C Function} scm_leaf_environment_p (object)
410 Return @code{#t} if object is a leaf environment, or @code{#f}
411 otherwise.
412 @end deffn
413
414 @deffn {Scheme Procedure} make-eval-environment local imported
415 @deffnx {C Function} scm_make_eval_environment (local, imported)
416 Return a new environment object eval whose bindings are the
417 union of the bindings in the environments @var{local} and
418 @var{imported}, with bindings from @var{local} taking
419 precedence. Definitions made in eval are placed in @var{local}.
420 Applying @code{environment-define} or
421 @code{environment-undefine} to eval has the same effect as
422 applying the procedure to @var{local}.
423 Note that eval incorporates @var{local} and @var{imported} by
424 reference:
425 If, after creating eval, the program changes the bindings of
426 @var{local} or @var{imported}, those changes will be visible
427 in eval.
428 Since most Scheme evaluation takes place in eval environments,
429 they transparently cache the bindings received from @var{local}
430 and @var{imported}. Thus, the first time the program looks up
431 a symbol in eval, eval may make calls to @var{local} or
432 @var{imported} to find their bindings, but subsequent
433 references to that symbol will be as fast as references to
434 bindings in finite environments.
435 In typical use, @var{local} will be a finite environment, and
436 @var{imported} will be an import environment
437 @end deffn
438
439 @deffn {Scheme Procedure} eval-environment? object
440 @deffnx {C Function} scm_eval_environment_p (object)
441 Return @code{#t} if object is an eval environment, or @code{#f}
442 otherwise.
443 @end deffn
444
445 @deffn {Scheme Procedure} eval-environment-local env
446 @deffnx {C Function} scm_eval_environment_local (env)
447 Return the local environment of eval environment @var{env}.
448 @end deffn
449
450 @deffn {Scheme Procedure} eval-environment-set-local! env local
451 @deffnx {C Function} scm_eval_environment_set_local_x (env, local)
452 Change @var{env}'s local environment to @var{local}.
453 @end deffn
454
455 @deffn {Scheme Procedure} eval-environment-imported env
456 @deffnx {C Function} scm_eval_environment_imported (env)
457 Return the imported environment of eval environment @var{env}.
458 @end deffn
459
460 @deffn {Scheme Procedure} eval-environment-set-imported! env imported
461 @deffnx {C Function} scm_eval_environment_set_imported_x (env, imported)
462 Change @var{env}'s imported environment to @var{imported}.
463 @end deffn
464
465 @deffn {Scheme Procedure} make-import-environment imports conflict_proc
466 @deffnx {C Function} scm_make_import_environment (imports, conflict_proc)
467 Return a new environment @var{imp} whose bindings are the union
468 of the bindings from the environments in @var{imports};
469 @var{imports} must be a list of environments. That is,
470 @var{imp} binds a symbol to a location when some element of
471 @var{imports} does.
472 If two different elements of @var{imports} have a binding for
473 the same symbol, the @var{conflict-proc} is called with the
474 following parameters:  the import environment, the symbol and
475 the list of the imported environments that bind the symbol.
476 If the @var{conflict-proc} returns an environment @var{env},
477 the conflict is considered as resolved and the binding from
478 @var{env} is used.  If the @var{conflict-proc} returns some
479 non-environment object, the conflict is considered unresolved
480 and the symbol is treated as unspecified in the import
481 environment.
482 The checking for conflicts may be performed lazily, i. e. at
483 the moment when a value or binding for a certain symbol is
484 requested instead of the moment when the environment is
485 created or the bindings of the imports change.
486 All bindings in @var{imp} are immutable. If you apply
487 @code{environment-define} or @code{environment-undefine} to
488 @var{imp}, Guile will signal an
489  @code{environment:immutable-binding} error. However,
490 notice that the set of bindings in @var{imp} may still change,
491 if one of its imported environments changes.
492 @end deffn
493
494 @deffn {Scheme Procedure} import-environment? object
495 @deffnx {C Function} scm_import_environment_p (object)
496 Return @code{#t} if object is an import environment, or
497 @code{#f} otherwise.
498 @end deffn
499
500 @deffn {Scheme Procedure} import-environment-imports env
501 @deffnx {C Function} scm_import_environment_imports (env)
502 Return the list of environments imported by the import
503 environment @var{env}.
504 @end deffn
505
506 @deffn {Scheme Procedure} import-environment-set-imports! env imports
507 @deffnx {C Function} scm_import_environment_set_imports_x (env, imports)
508 Change @var{env}'s list of imported environments to
509 @var{imports}, and check for conflicts.
510 @end deffn
511
512 @deffn {Scheme Procedure} make-export-environment private signature
513 @deffnx {C Function} scm_make_export_environment (private, signature)
514 Return a new environment @var{exp} containing only those
515 bindings in private whose symbols are present in
516 @var{signature}. The @var{private} argument must be an
517 environment.
518
519 The environment @var{exp} binds symbol to location when
520 @var{env} does, and symbol is exported by @var{signature}.
521
522 @var{signature} is a list specifying which of the bindings in
523 @var{private} should be visible in @var{exp}. Each element of
524 @var{signature} should be a list of the form:
525   (symbol attribute ...)
526 where each attribute is one of the following:
527 @table @asis
528 @item the symbol @code{mutable-location}
529   @var{exp} should treat the
530   location bound to symbol as mutable. That is, @var{exp}
531   will pass calls to @code{environment-set!} or
532   @code{environment-cell} directly through to private.
533 @item the symbol @code{immutable-location}
534   @var{exp} should treat
535   the location bound to symbol as immutable. If the program
536   applies @code{environment-set!} to @var{exp} and symbol, or
537   calls @code{environment-cell} to obtain a writable value
538   cell, @code{environment-set!} will signal an
539   @code{environment:immutable-location} error. Note that, even
540   if an export environment treats a location as immutable, the
541   underlying environment may treat it as mutable, so its
542   value may change.
543 @end table
544 It is an error for an element of signature to specify both
545 @code{mutable-location} and @code{immutable-location}. If
546 neither is specified, @code{immutable-location} is assumed.
547
548 As a special case, if an element of signature is a lone
549 symbol @var{sym}, it is equivalent to an element of the form
550 @code{(sym)}.
551
552 All bindings in @var{exp} are immutable. If you apply
553 @code{environment-define} or @code{environment-undefine} to
554 @var{exp}, Guile will signal an
555 @code{environment:immutable-binding} error. However,
556 notice that the set of bindings in @var{exp} may still change,
557 if the bindings in private change.
558 @end deffn
559
560 @deffn {Scheme Procedure} export-environment? object
561 @deffnx {C Function} scm_export_environment_p (object)
562 Return @code{#t} if object is an export environment, or
563 @code{#f} otherwise.
564 @end deffn
565
566 @deffn {Scheme Procedure} export-environment-private env
567 @deffnx {C Function} scm_export_environment_private (env)
568 Return the private environment of export environment @var{env}.
569 @end deffn
570
571 @deffn {Scheme Procedure} export-environment-set-private! env private
572 @deffnx {C Function} scm_export_environment_set_private_x (env, private)
573 Change the private environment of export environment @var{env}.
574 @end deffn
575
576 @deffn {Scheme Procedure} export-environment-signature env
577 @deffnx {C Function} scm_export_environment_signature (env)
578 Return the signature of export environment @var{env}.
579 @end deffn
580
581 @deffn {Scheme Procedure} export-environment-set-signature! env signature
582 @deffnx {C Function} scm_export_environment_set_signature_x (env, signature)
583 Change the signature of export environment @var{env}.
584 @end deffn
585
586 @deffn {Scheme Procedure} %compute-slots class
587 @deffnx {C Function} scm_sys_compute_slots (class)
588 Return a list consisting of the names of all slots belonging to
589 class @var{class}, i. e. the slots of @var{class} and of all of
590 its superclasses.
591 @end deffn
592
593 @deffn {Scheme Procedure} get-keyword key l default_value
594 @deffnx {C Function} scm_get_keyword (key, l, default_value)
595 Determine an associated value for the keyword @var{key} from
596 the list @var{l}.  The list @var{l} has to consist of an even
597 number of elements, where, starting with the first, every
598 second element is a keyword, followed by its associated value.
599 If @var{l} does not hold a value for @var{key}, the value
600 @var{default_value} is returned.
601 @end deffn
602
603 @deffn {Scheme Procedure} slot-ref-using-class class obj slot_name
604 @deffnx {C Function} scm_slot_ref_using_class (class, obj, slot_name)
605
606 @end deffn
607
608 @deffn {Scheme Procedure} slot-set-using-class! class obj slot_name value
609 @deffnx {C Function} scm_slot_set_using_class_x (class, obj, slot_name, value)
610
611 @end deffn
612
613 @deffn {Scheme Procedure} class-of x
614 @deffnx {C Function} scm_class_of (x)
615 Return the class of @var{x}.
616 @end deffn
617
618 @deffn {Scheme Procedure} %goops-loaded
619 @deffnx {C Function} scm_sys_goops_loaded ()
620 Announce that GOOPS is loaded and perform initialization
621 on the C level which depends on the loaded GOOPS modules.
622 @end deffn
623
624 @deffn {Scheme Procedure} %method-more-specific? m1 m2 targs
625 @deffnx {C Function} scm_sys_method_more_specific_p (m1, m2, targs)
626
627 @end deffn
628
629 @deffn {Scheme Procedure} find-method . l
630 @deffnx {C Function} scm_find_method (l)
631
632 @end deffn
633
634 @deffn {Scheme Procedure} primitive-generic-generic subr
635 @deffnx {C Function} scm_primitive_generic_generic (subr)
636
637 @end deffn
638
639 @deffn {Scheme Procedure} enable-primitive-generic! . subrs
640 @deffnx {C Function} scm_enable_primitive_generic_x (subrs)
641
642 @end deffn
643
644 @deffn {Scheme Procedure} generic-capability? proc
645 @deffnx {C Function} scm_generic_capability_p (proc)
646
647 @end deffn
648
649 @deffn {Scheme Procedure} %invalidate-method-cache! gf
650 @deffnx {C Function} scm_sys_invalidate_method_cache_x (gf)
651
652 @end deffn
653
654 @deffn {Scheme Procedure} %invalidate-class class
655 @deffnx {C Function} scm_sys_invalidate_class (class)
656
657 @end deffn
658
659 @deffn {Scheme Procedure} %modify-class old new
660 @deffnx {C Function} scm_sys_modify_class (old, new)
661
662 @end deffn
663
664 @deffn {Scheme Procedure} %modify-instance old new
665 @deffnx {C Function} scm_sys_modify_instance (old, new)
666
667 @end deffn
668
669 @deffn {Scheme Procedure} %set-object-setter! obj setter
670 @deffnx {C Function} scm_sys_set_object_setter_x (obj, setter)
671
672 @end deffn
673
674 @deffn {Scheme Procedure} %allocate-instance class initargs
675 @deffnx {C Function} scm_sys_allocate_instance (class, initargs)
676 Create a new instance of class @var{class} and initialize it
677 from the arguments @var{initargs}.
678 @end deffn
679
680 @deffn {Scheme Procedure} slot-exists? obj slot_name
681 @deffnx {C Function} scm_slot_exists_p (obj, slot_name)
682 Return @code{#t} if @var{obj} has a slot named @var{slot_name}.
683 @end deffn
684
685 @deffn {Scheme Procedure} slot-bound? obj slot_name
686 @deffnx {C Function} scm_slot_bound_p (obj, slot_name)
687 Return @code{#t} if the slot named @var{slot_name} of @var{obj}
688 is bound.
689 @end deffn
690
691 @deffn {Scheme Procedure} slot-set! obj slot_name value
692 @deffnx {C Function} scm_slot_set_x (obj, slot_name, value)
693 Set the slot named @var{slot_name} of @var{obj} to @var{value}.
694 @end deffn
695
696 @deffn {Scheme Procedure} slot-exists-using-class? class obj slot_name
697 @deffnx {C Function} scm_slot_exists_using_class_p (class, obj, slot_name)
698
699 @end deffn
700
701 @deffn {Scheme Procedure} slot-bound-using-class? class obj slot_name
702 @deffnx {C Function} scm_slot_bound_using_class_p (class, obj, slot_name)
703
704 @end deffn
705
706 @deffn {Scheme Procedure} %fast-slot-set! obj index value
707 @deffnx {C Function} scm_sys_fast_slot_set_x (obj, index, value)
708 Set the slot with index @var{index} in @var{obj} to
709 @var{value}.
710 @end deffn
711
712 @deffn {Scheme Procedure} %fast-slot-ref obj index
713 @deffnx {C Function} scm_sys_fast_slot_ref (obj, index)
714 Return the slot value with index @var{index} from @var{obj}.
715 @end deffn
716
717 @deffn {Scheme Procedure} @@assert-bound-ref obj index
718 @deffnx {C Function} scm_at_assert_bound_ref (obj, index)
719 Like @code{assert-bound}, but use @var{index} for accessing
720 the value from @var{obj}.
721 @end deffn
722
723 @deffn {Scheme Procedure} assert-bound value obj
724 @deffnx {C Function} scm_assert_bound (value, obj)
725 Return @var{value} if it is bound, and invoke the
726 @var{slot-unbound} method of @var{obj} if it is not.
727 @end deffn
728
729 @deffn {Scheme Procedure} unbound? obj
730 @deffnx {C Function} scm_unbound_p (obj)
731 Return @code{#t} if @var{obj} is unbound.
732 @end deffn
733
734 @deffn {Scheme Procedure} make-unbound
735 @deffnx {C Function} scm_make_unbound ()
736 Return the unbound value.
737 @end deffn
738
739 @deffn {Scheme Procedure} accessor-method-slot-definition obj
740 @deffnx {C Function} scm_accessor_method_slot_definition (obj)
741 Return the slot definition of the accessor @var{obj}.
742 @end deffn
743
744 @deffn {Scheme Procedure} method-procedure obj
745 @deffnx {C Function} scm_method_procedure (obj)
746 Return the procedure of the method @var{obj}.
747 @end deffn
748
749 @deffn {Scheme Procedure} method-specializers obj
750 @deffnx {C Function} scm_method_specializers (obj)
751 Return specializers of the method @var{obj}.
752 @end deffn
753
754 @deffn {Scheme Procedure} method-generic-function obj
755 @deffnx {C Function} scm_method_generic_function (obj)
756 Return the generic function for the method @var{obj}.
757 @end deffn
758
759 @deffn {Scheme Procedure} generic-function-methods obj
760 @deffnx {C Function} scm_generic_function_methods (obj)
761 Return the methods of the generic function @var{obj}.
762 @end deffn
763
764 @deffn {Scheme Procedure} generic-function-name obj
765 @deffnx {C Function} scm_generic_function_name (obj)
766 Return the name of the generic function @var{obj}.
767 @end deffn
768
769 @deffn {Scheme Procedure} class-environment obj
770 @deffnx {C Function} scm_class_environment (obj)
771 Return the environment of the class @var{obj}.
772 @end deffn
773
774 @deffn {Scheme Procedure} class-slots obj
775 @deffnx {C Function} scm_class_slots (obj)
776 Return the slot list of the class @var{obj}.
777 @end deffn
778
779 @deffn {Scheme Procedure} class-precedence-list obj
780 @deffnx {C Function} scm_class_precedence_list (obj)
781 Return the class precedence list of the class @var{obj}.
782 @end deffn
783
784 @deffn {Scheme Procedure} class-direct-methods obj
785 @deffnx {C Function} scm_class_direct_methods (obj)
786 Return the direct methods of the class @var{obj}
787 @end deffn
788
789 @deffn {Scheme Procedure} class-direct-subclasses obj
790 @deffnx {C Function} scm_class_direct_subclasses (obj)
791 Return the direct subclasses of the class @var{obj}.
792 @end deffn
793
794 @deffn {Scheme Procedure} class-direct-slots obj
795 @deffnx {C Function} scm_class_direct_slots (obj)
796 Return the direct slots of the class @var{obj}.
797 @end deffn
798
799 @deffn {Scheme Procedure} class-direct-supers obj
800 @deffnx {C Function} scm_class_direct_supers (obj)
801 Return the direct superclasses of the class @var{obj}.
802 @end deffn
803
804 @deffn {Scheme Procedure} class-name obj
805 @deffnx {C Function} scm_class_name (obj)
806 Return the class name of @var{obj}.
807 @end deffn
808
809 @deffn {Scheme Procedure} instance? obj
810 @deffnx {C Function} scm_instance_p (obj)
811 Return @code{#t} if @var{obj} is an instance.
812 @end deffn
813
814 @deffn {Scheme Procedure} %inherit-magic! class dsupers
815 @deffnx {C Function} scm_sys_inherit_magic_x (class, dsupers)
816
817 @end deffn
818
819 @deffn {Scheme Procedure} %prep-layout! class
820 @deffnx {C Function} scm_sys_prep_layout_x (class)
821
822 @end deffn
823
824 @deffn {Scheme Procedure} %initialize-object obj initargs
825 @deffnx {C Function} scm_sys_initialize_object (obj, initargs)
826 Initialize the object @var{obj} with the given arguments
827 @var{initargs}.
828 @end deffn
829
830 @deffn {Scheme Procedure} make . args
831 @deffnx {C Function} scm_make (args)
832 Make a new object.  @var{args} must contain the class and
833 all necessary initialization information.
834 @end deffn
835
836 @deffn {Scheme Procedure} slot-ref obj slot_name
837 @deffnx {C Function} scm_slot_ref (obj, slot_name)
838 Return the value from @var{obj}'s slot with the name
839 @var{slot_name}.
840 @end deffn
841
842 @deffn {Scheme Procedure} %tag-body body
843 @deffnx {C Function} scm_sys_tag_body (body)
844 Internal GOOPS magic---don't use this function!
845 @end deffn
846
847 @deffn {Scheme Procedure} make-keyword-from-dash-symbol symbol
848 @deffnx {C Function} scm_make_keyword_from_dash_symbol (symbol)
849 Make a keyword object from a @var{symbol} that starts with a dash.
850 @end deffn
851
852 @deffn {Scheme Procedure} keyword-dash-symbol keyword
853 @deffnx {C Function} scm_keyword_dash_symbol (keyword)
854 Return the dash symbol for @var{keyword}.
855 This is the inverse of @code{make-keyword-from-dash-symbol}.
856 @end deffn
857
858 @deffn {Scheme Procedure} dimensions->uniform-array dims prot [fill]
859 @deffnx {Scheme Procedure} make-uniform-vector length prototype [fill]
860 @deffnx {C Function} scm_dimensions_to_uniform_array (dims, prot, fill)
861 Create and return a uniform array or vector of type
862 corresponding to @var{prototype} with dimensions @var{dims} or
863 length @var{length}.  If @var{fill} is supplied, it's used to
864 fill the array, otherwise @var{prototype} is used.
865 @end deffn
866
867 @deffn {Scheme Procedure} list->uniform-array ndim prot lst
868 @deffnx {C Function} scm_list_to_uniform_array (ndim, prot, lst)
869 Return a uniform array of the type indicated by prototype
870 @var{prot} with elements the same as those of @var{lst}.
871 Elements must be of the appropriate type, no coercions are
872 done.
873
874 The argument @var{ndim} determines the number of dimensions
875 of the array.  It is either an exact integer, giving the
876 number directly, or a list of exact integers, whose length
877 specifies the number of dimensions and each element is the
878 lower index bound of its dimension.
879 @end deffn
880
881 @deffn {Scheme Procedure} array-prototype ra
882 @deffnx {C Function} scm_array_prototype (ra)
883 Return an object that would produce an array of the same type
884 as @var{array}, if used as the @var{prototype} for
885 @code{make-uniform-array}.
886 @end deffn
887
888 @deffn {Scheme Procedure} call-with-dynamic-root thunk handler
889 @deffnx {C Function} scm_call_with_dynamic_root (thunk, handler)
890 Call @var{thunk} with a new dynamic state and withina continuation barrier.  The @var{handler} catches allotherwise uncaught throws and executes within the samedynamic context as @var{thunk}.
891 @end deffn
892
893 @deffn {Scheme Procedure} dynamic-root
894 @deffnx {C Function} scm_dynamic_root ()
895 Return an object representing the current dynamic root.
896
897 These objects are only useful for comparison using @code{eq?}.
898
899 @end deffn
900
901 @deffn {Scheme Procedure} uniform-vector? obj
902 @deffnx {C Function} scm_uniform_vector_p (obj)
903 Return @code{#t} if @var{obj} is a uniform vector.
904 @end deffn
905
906 @deffn {Scheme Procedure} uniform-vector-ref v idx
907 @deffnx {C Function} scm_uniform_vector_ref (v, idx)
908 Return the element at index @var{idx} of the
909 homogenous numeric vector @var{v}.
910 @end deffn
911
912 @deffn {Scheme Procedure} uniform-vector-set! v idx val
913 @deffnx {C Function} scm_uniform_vector_set_x (v, idx, val)
914 Set the element at index @var{idx} of the
915 homogenous numeric vector @var{v} to @var{val}.
916 @end deffn
917
918 @deffn {Scheme Procedure} uniform-vector->list uvec
919 @deffnx {C Function} scm_uniform_vector_to_list (uvec)
920 Convert the uniform numeric vector @var{uvec} to a list.
921 @end deffn
922
923 @deffn {Scheme Procedure} uniform-vector-length v
924 @deffnx {C Function} scm_uniform_vector_length (v)
925 Return the number of elements in the uniform vector @var{v}.
926 @end deffn
927
928 @deffn {Scheme Procedure} make-u8vector len [fill]
929 @deffnx {C Function} scm_make_u8vector (len, fill)
930 Return a newly allocated uniform numeric vector which can
931 hold @var{len} elements.  If @var{fill} is given, it is used to
932 initialize the elements, otherwise the contents of the vector
933 is unspecified.
934 @end deffn
935
936 @deffn {Scheme Procedure} u8vector . l
937 @deffnx {C Function} scm_u8vector (l)
938 Return a newly allocated uniform numeric vector containing
939 all argument values.
940 @end deffn
941
942 @deffn {Scheme Procedure} list->u8vector l
943 @deffnx {C Function} scm_list_to_u8vector (l)
944 Convert the list @var{l} to a numeric uniform vector.
945 @end deffn
946
947 @deffn {Scheme Procedure} any->u8vector obj
948 @deffnx {C Function} scm_any_to_u8vector (obj)
949 Convert @var{obj}, which can be a list, vector, or
950 uniform vector, to a numeric uniform vector of
951 type u8.
952 @end deffn
953
954 @deffn {Scheme Procedure} string-any-c-code char_pred s [start [end]]
955 @deffnx {C Function} scm_string_any (char_pred, s, start, end)
956 Check if the predicate @var{pred} is true for any character in
957 the string @var{s}.
958
959 Calls to @var{pred} are made from left to right across @var{s}.
960 When it returns true (ie.@: non-@code{#f}), that return value
961 is the return from @code{string-any}.
962
963 The SRFI-13 specification requires that the call to @var{pred}
964 on the last character of @var{s} (assuming that point is
965 reached) be a tail call, but currently in Guile this is not the
966 case.
967 @end deffn
968
969 @deffn {Scheme Procedure} string-every-c-code char_pred s [start [end]]
970 @deffnx {C Function} scm_string_every (char_pred, s, start, end)
971 Check if the predicate @var{pred} is true for every character
972 in the string @var{s}.
973
974 Calls to @var{pred} are made from left to right across @var{s}.
975 If the predicate is true for every character then the return
976 value from the last @var{pred} call is the return from
977 @code{string-every}.
978
979 If there are no characters in @var{s} (ie.@: @var{start} equals
980 @var{end}) then the return is @code{#t}.
981
982 The SRFI-13 specification requires that the call to @var{pred}
983 on the last character of @var{s} (assuming that point is
984 reached) be a tail call, but currently in Guile this is not the
985 case.
986 @end deffn
987
988 @deffn {Scheme Procedure} inf? x
989 @deffnx {C Function} scm_inf_p (x)
990 Return @code{#t} if @var{x} is either @samp{+inf.0}
991 or @samp{-inf.0}, @code{#f} otherwise.
992 @end deffn
993
994