[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
guile/guile-core/libguile gh_data.c gh.h
From: |
Marius Vollmer |
Subject: |
guile/guile-core/libguile gh_data.c gh.h |
Date: |
Mon, 07 May 2001 11:11:21 -0700 |
CVSROOT: /cvs
Module name: guile
Changes by: Marius Vollmer <address@hidden> 01/05/07 11:11:21
Modified files:
guile-core/libguile: gh_data.c gh.h
Log message:
(gh_lookup): Call gh_module_lookup with
`scm_current_module ()', not `#f'.
(gh_module_lookup): Expect a module instead of an obarray as first
argument and do lookup in that module.
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/guile/guile-core/libguile/gh_data.c.diff?cvsroot=OldCVS&tr1=1.57&tr2=1.58&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/guile/guile-core/libguile/gh.h.diff?cvsroot=OldCVS&tr1=1.30&tr2=1.31&r1=text&r2=text
Patches:
Index: guile/guile-core/libguile/gh.h
diff -u guile/guile-core/libguile/gh.h:1.30 guile/guile-core/libguile/gh.h:1.31
--- guile/guile-core/libguile/gh.h:1.30 Tue May 1 17:43:01 2001
+++ guile/guile-core/libguile/gh.h Mon May 7 11:11:20 2001
@@ -185,7 +185,7 @@
#define gh_vector_to_list(v) scm_vector_to_list(v)
SCM gh_lookup (const char *sname);
-SCM gh_module_lookup (SCM vector, const char *sname);
+SCM gh_module_lookup (SCM module, const char *sname);
SCM gh_cons(SCM x, SCM y);
#define gh_list scm_listify
Index: guile/guile-core/libguile/gh_data.c
diff -u guile/guile-core/libguile/gh_data.c:1.57
guile/guile-core/libguile/gh_data.c:1.58
--- guile/guile-core/libguile/gh_data.c:1.57 Sat Apr 28 10:23:48 2001
+++ guile/guile-core/libguile/gh_data.c Mon May 7 11:11:20 2001
@@ -700,18 +700,26 @@
SCM
gh_lookup (const char *sname)
{
- return gh_module_lookup (SCM_BOOL_F, sname);
+ return gh_module_lookup (scm_current_module (), sname);
}
+
SCM
-gh_module_lookup (SCM vec, const char *sname)
+gh_module_lookup (SCM module, const char *sname)
+#define FUNC_NAME "gh_module_lookup"
{
- SCM sym = gh_symbol2scm (sname);
- if (SCM_EQ_P (scm_symbol_bound_p (vec, sym), SCM_BOOL_T))
- return scm_symbol_binding (vec, sym);
+ SCM sym, cell;
+
+ SCM_VALIDATE_MODULE (SCM_ARG1, module);
+
+ sym = gh_symbol2scm (sname);
+ cell = scm_sym2vcell (sym, scm_module_lookup_closure (module), SCM_BOOL_F);
+ if (cell != SCM_BOOL_F)
+ return SCM_CDR (cell);
else
return SCM_UNDEFINED;
}
+#undef FUNC_NAME
/*
Local Variables:
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- guile/guile-core/libguile gh_data.c gh.h,
Marius Vollmer <=