remove libraries procedure
This commit is contained in:
parent
8610f5090d
commit
95740b86a0
|
@ -18,4 +18,6 @@ pic_init_r7rs(pic_state *pic)
|
|||
pic_init_mutable_string(pic);
|
||||
pic_init_system(pic);
|
||||
pic_init_time(pic);
|
||||
|
||||
pic_add_feature(pic, "r7rs");
|
||||
}
|
||||
|
|
23
src/main.c
23
src/main.c
|
@ -4,30 +4,11 @@
|
|||
|
||||
#include "picrin.h"
|
||||
|
||||
void pic_init_contrib(pic_state *);
|
||||
void pic_load_piclib(pic_state *);
|
||||
|
||||
static pic_value
|
||||
pic_libraries(pic_state *pic)
|
||||
{
|
||||
pic_value libs = pic_nil_value(), lib, it;
|
||||
|
||||
pic_get_args(pic, "");
|
||||
|
||||
pic_for_each (lib, pic->libs, it) {
|
||||
libs = pic_cons(pic, pic_car(pic, lib), libs);
|
||||
}
|
||||
|
||||
return libs;
|
||||
}
|
||||
|
||||
void
|
||||
pic_init_picrin(pic_state *pic)
|
||||
{
|
||||
pic_add_feature(pic, "r7rs");
|
||||
|
||||
pic_deflibrary(pic, "(picrin library)");
|
||||
pic_defun(pic, "libraries", pic_libraries);
|
||||
void pic_init_contrib(pic_state *);
|
||||
void pic_load_piclib(pic_state *);
|
||||
|
||||
pic_init_contrib(pic);
|
||||
pic_load_piclib(pic);
|
||||
|
|
Loading…
Reference in New Issue