diff options
author | Mark Galassi <mark+savannah@galassi.org> | 1997-11-25 06:18:08 +0000 |
---|---|---|
committer | Mark Galassi <mark+savannah@galassi.org> | 1997-11-25 06:18:08 +0000 |
commit | ef5d3ae17549e4da69dbbba316f5722a5d2f9ea0 (patch) | |
tree | fd4bbc8150019c82df8f827b2ccb4065c6a0e3e2 | |
parent | 774b7f2281a1a29576b52ff4f99c2e97c102b434 (diff) | |
download | guile-ef5d3ae17549e4da69dbbba316f5722a5d2f9ea0.tar.gz |
made changes in gh_repl() and started adding the uniform array stuff to gh_
-rw-r--r-- | libguile/ChangeLog | 14 | ||||
-rw-r--r-- | libguile/gh_data.c | 24 | ||||
-rw-r--r-- | libguile/gh_init.c | 8 |
3 files changed, 42 insertions, 4 deletions
diff --git a/libguile/ChangeLog b/libguile/ChangeLog index 0640cfc88..febe9144a 100644 --- a/libguile/ChangeLog +++ b/libguile/ChangeLog @@ -1,3 +1,11 @@ +1997-11-24 Mark Galassi <rosalia@nis.lanl.gov> + + * gh_init.c (gh_repl): modified gh_repl() to accept argc and argv + and to invoke scm_shell(). + (gh_launch_pad): took out the loading of boot-9.scm from here, + since it is probably best to let the user control that. In fact, + gh_repl() now invokes scm_shell() which does that. + 1997-11-22 Tim Pierce <twp@twp.tezcat.com> * dynl-dl.c (sysdep_dynl_func): Fix memory leak created by @@ -9,6 +17,12 @@ * dynl-dl.c (sysdep_dynl_func): Prepend symb with underscore if DLSYM_ADDS_USCORE is not defined. +1997-11-17 Mark Galassi <rosalia@nis.lanl.gov> + + * gh_data.c (gh_uniform_vector_length): + (gh_uniform_vector_ref): started implementing the uniform types in + the gh_ interface. + 1997-11-06 Mikael Djurfeldt <mdj@nada.kth.se> * regex-posix.c (scm_free_regex_t): Return size of regex_t instead diff --git a/libguile/gh_data.c b/libguile/gh_data.c index 1be6a6702..2c067cc5b 100644 --- a/libguile/gh_data.c +++ b/libguile/gh_data.c @@ -295,6 +295,30 @@ gh_vector_length (SCM v) return gh_scm2ulong (scm_vector_length (v)); } + +/* uniform vector support */ + +/* returns the length as a C unsigned long integer */ +unsigned long +gh_uniform_vector_length (SCM v) +{ + return gh_scm2ulong (scm_uniform_vector_length (v)); +} + +/* gets the given element from a uniform vector; ilist is a list (or + possibly a single integer) of indices, and its length is the + dimension of the uniform vector */ +SCM +gh_uniform_vector_ref (SCM v, SCM ilist) +{ + return scm_uniform_vector_ref (v, ilist); +} + +/* sets an individual element in a uniform vector */ +/* SCM */ +/* gh_list_to_uniform_array ( */ + + /* Data lookups between C and Scheme Look up a symbol with a given name, and return the object to which diff --git a/libguile/gh_init.c b/libguile/gh_init.c index e2e58f23a..eb6858bd2 100644 --- a/libguile/gh_init.c +++ b/libguile/gh_init.c @@ -57,7 +57,7 @@ gh_launch_pad (void *closure, int argc, char **argv) { main_prog_t c_main_prog = (main_prog_t) closure; - gh_eval_str ("(primitive-load-path \"ice-9/boot-9.scm\")"); +/* gh_eval_str ("(primitive-load-path \"ice-9/boot-9.scm\")"); */ c_main_prog (argc, argv); exit (0); } @@ -76,10 +76,10 @@ gh_enter (int argc, char *argv[], main_prog_t c_main_prog) /* offer a REPL to the C programmer; for now I just invoke the ice-9 REPL that is written in Scheme */ void -gh_repl () +gh_repl (int argc, char *argv[]) { -/* gh_eval_str("(primitive-load-path \"ice-9/boot-9.scm\")"); */ - gh_eval_str ("(top-repl)"); +/* gh_eval_str ("(top-repl)"); */ + scm_shell (argc, argv); } /* libguile programmers need exception handling mechanisms; here is |