struct pic_weak * -> pic_value
This commit is contained in:
@@ -242,11 +242,11 @@ int pic_dict_size(pic_state *, pic_value dict);
|
||||
bool pic_dict_next(pic_state *, pic_value dict, int *iter, pic_sym **key, pic_value *val);
|
||||
|
||||
/* ephemeron */
|
||||
struct pic_weak *pic_make_weak(pic_state *);
|
||||
pic_value pic_weak_ref(pic_state *, struct pic_weak *, void *);
|
||||
void pic_weak_set(pic_state *, struct pic_weak *, void *, pic_value);
|
||||
void pic_weak_del(pic_state *, struct pic_weak *, void *);
|
||||
bool pic_weak_has(pic_state *, struct pic_weak *, void *);
|
||||
pic_value pic_make_weak(pic_state *);
|
||||
pic_value pic_weak_ref(pic_state *, pic_value weak, pic_value key);
|
||||
void pic_weak_set(pic_state *, pic_value weak, pic_value key, pic_value val);
|
||||
void pic_weak_del(pic_state *, pic_value weak, pic_value key);
|
||||
bool pic_weak_has(pic_state *, pic_value weak, pic_value key);
|
||||
|
||||
/* symbol */
|
||||
pic_sym *pic_intern(pic_state *, pic_value str);
|
||||
|
||||
@@ -11,7 +11,7 @@ extern "C" {
|
||||
|
||||
KHASH_DECLARE(env, pic_id *, pic_sym *)
|
||||
KHASH_DECLARE(dict, pic_sym *, pic_value)
|
||||
KHASH_DECLARE(weak, void *, pic_value)
|
||||
KHASH_DECLARE(weak, struct pic_object *, pic_value)
|
||||
|
||||
struct pic_id {
|
||||
union {
|
||||
@@ -125,11 +125,11 @@ struct pic_port {
|
||||
#define pic_pair_ptr(pic, o) ((struct pic_pair *)pic_obj_ptr(o))
|
||||
#define pic_vec_ptr(pic, o) ((struct pic_vector *)pic_obj_ptr(o))
|
||||
#define pic_dict_ptr(pic, o) ((struct pic_dict *)pic_obj_ptr(o))
|
||||
#define pic_weak_ptr(pic, o) ((struct pic_weak *)pic_obj_ptr(o))
|
||||
#define pic_data_ptr(pic, o) ((struct pic_data *)pic_obj_ptr(o))
|
||||
#define pic_proc_ptr(pic, o) ((struct pic_proc *)pic_obj_ptr(o))
|
||||
#define pic_sym_ptr(v) ((pic_sym *)pic_obj_ptr(v))
|
||||
#define pic_id_ptr(v) ((pic_id *)pic_obj_ptr(v))
|
||||
#define pic_weak_ptr(v) ((struct pic_weak *)pic_obj_ptr(v))
|
||||
#define pic_context_ptr(o) ((struct pic_context *)pic_obj_ptr(o))
|
||||
#define pic_rec_ptr(v) ((struct pic_record *)pic_obj_ptr(v))
|
||||
#define pic_error_ptr(v) ((struct pic_error *)pic_obj_ptr(v))
|
||||
|
||||
@@ -79,8 +79,8 @@ struct pic_state {
|
||||
|
||||
khash_t(oblist) oblist; /* string to symbol */
|
||||
int ucnt;
|
||||
struct pic_weak *globals;
|
||||
struct pic_weak *macros;
|
||||
pic_value globals; /* weak */
|
||||
pic_value macros; /* weak */
|
||||
khash_t(ltable) ltable;
|
||||
struct pic_list ireps; /* chain */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user