mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 03:40:34 +02:00
* modules.h, modules.c: Moved around a lot of code so that
deprecated features appear at the bottom. (root_module_lookup_closure, scm_sym_app, scm_sym_modules, module_prefix, make_modules_in_var, beautify_user_module_x_var, scm_the_root_module, scm_make_module, scm_ensure_user_module, scm_load_scheme_module): Deprecated. (scm_system_module_env_p): Return SCM_BOOL_T directly for environments corresponding to the root module. (convert_module_name, scm_c_resolve_module, scm_c_call_with_current_module, scm_c_define_module, scm_c_use_module, scm_c_export): New. (the_root_module): New static variant of scm_the_root_module. Use it everywhere instead of scm_the_root_module.
This commit is contained in:
parent
143e090215
commit
d02b98e960
2 changed files with 257 additions and 122 deletions
|
@ -50,6 +50,9 @@
|
|||
|
||||
|
||||
|
||||
extern int scm_module_system_booted_p;
|
||||
extern SCM scm_module_tag;
|
||||
|
||||
#define SCM_MODULEP(OBJ) \
|
||||
(SCM_NIMP (OBJ) && SCM_CELL_TYPE (OBJ) == scm_module_tag)
|
||||
|
||||
|
@ -82,31 +85,12 @@ extern scm_bits_t scm_tc16_eval_closure;
|
|||
|
||||
|
||||
|
||||
extern int scm_module_system_booted_p;
|
||||
extern SCM scm_module_tag;
|
||||
|
||||
extern SCM scm_the_root_module (void);
|
||||
extern SCM scm_current_module (void);
|
||||
extern SCM scm_current_module_lookup_closure (void);
|
||||
extern SCM scm_current_module_transformer (void);
|
||||
extern SCM scm_interaction_environment (void);
|
||||
extern SCM scm_set_current_module (SCM module);
|
||||
extern SCM scm_make_module (SCM name);
|
||||
extern SCM scm_ensure_user_module (SCM name);
|
||||
extern SCM scm_module_lookup_closure (SCM module);
|
||||
extern SCM scm_module_transformer (SCM module);
|
||||
extern SCM scm_resolve_module (SCM name);
|
||||
extern SCM scm_load_scheme_module (SCM name);
|
||||
extern SCM scm_env_top_level (SCM env);
|
||||
extern SCM scm_top_level_env (SCM thunk);
|
||||
extern SCM scm_system_module_env_p (SCM env);
|
||||
extern SCM scm_eval_closure_lookup (SCM eclo, SCM sym, SCM definep);
|
||||
extern SCM scm_standard_eval_closure (SCM module);
|
||||
extern SCM scm_standard_interface_eval_closure (SCM module);
|
||||
extern SCM scm_get_pre_modules_obarray (void);
|
||||
|
||||
extern SCM scm_lookup_closure_module (SCM proc);
|
||||
extern SCM scm_env_module (SCM env);
|
||||
extern SCM scm_c_call_with_current_module (SCM module,
|
||||
SCM (*func)(void *), void *data);
|
||||
|
||||
extern SCM scm_c_lookup (const char *name);
|
||||
extern SCM scm_c_define (const char *name, SCM val);
|
||||
|
@ -119,11 +103,42 @@ extern SCM scm_module_lookup (SCM module, SCM symbol);
|
|||
extern SCM scm_module_define (SCM module, SCM symbol, SCM val);
|
||||
extern SCM scm_module_reverse_lookup (SCM module, SCM variable);
|
||||
|
||||
extern SCM scm_c_resolve_module (const char *name);
|
||||
extern SCM scm_resolve_module (SCM name);
|
||||
extern SCM scm_c_define_module (const char *name,
|
||||
void (*init)(void *), void *data);
|
||||
extern void scm_c_use_module (const char *name);
|
||||
extern void scm_c_export (const char *name, ...);
|
||||
|
||||
extern SCM scm_sym2var (SCM sym, SCM thunk, SCM definep);
|
||||
|
||||
extern SCM scm_module_lookup_closure (SCM module);
|
||||
extern SCM scm_module_transformer (SCM module);
|
||||
extern SCM scm_current_module_lookup_closure (void);
|
||||
extern SCM scm_current_module_transformer (void);
|
||||
extern SCM scm_eval_closure_lookup (SCM eclo, SCM sym, SCM definep);
|
||||
extern SCM scm_standard_eval_closure (SCM module);
|
||||
extern SCM scm_standard_interface_eval_closure (SCM module);
|
||||
extern SCM scm_get_pre_modules_obarray (void);
|
||||
extern SCM scm_lookup_closure_module (SCM proc);
|
||||
|
||||
extern SCM scm_env_top_level (SCM env);
|
||||
extern SCM scm_env_module (SCM env);
|
||||
extern SCM scm_top_level_env (SCM thunk);
|
||||
|
||||
extern void scm_modules_prehistory (void);
|
||||
extern void scm_init_modules (void);
|
||||
|
||||
#if SCM_DEBUG_DEPRECATED == 0
|
||||
|
||||
extern SCM scm_the_root_module (void);
|
||||
extern SCM scm_make_module (SCM name);
|
||||
extern SCM scm_ensure_user_module (SCM name);
|
||||
extern SCM scm_load_scheme_module (SCM name);
|
||||
extern SCM scm_system_module_env_p (SCM env);
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* MODULESH */
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue