move symbol-related macros to symbol.h

This commit is contained in:
Yuichi Nishiwaki 2015-01-19 11:11:19 +09:00
parent fa1b681eba
commit 3fc49b59be
9 changed files with 10 additions and 3 deletions

View File

@ -9,6 +9,7 @@
#include "picrin/lib.h"
#include "picrin/macro.h"
#include "picrin/dict.h"
#include "picrin/symbol.h"
#if PIC_NONE_IS_FALSE
# define OP_PUSHNONE OP_PUSHFALSE

View File

@ -7,6 +7,7 @@
#include "picrin/cont.h"
#include "picrin/pair.h"
#include "picrin/error.h"
#include "picrin/symbol.h"
struct pic_dict *
pic_make_dict(pic_state *pic)

View File

@ -51,9 +51,6 @@ extern "C" {
#include "picrin/util.h"
#include "picrin/value.h"
#define pic_sym(v) pic_ptr(v)
#define pic_sym_p(v) (pic_type(v) == PIC_TT_SYMBOL)
typedef struct pic_code pic_code;
struct pic_winder {

View File

@ -14,6 +14,9 @@ struct pic_symbol {
pic_str *str;
};
#define pic_sym(v) pic_ptr(v)
#define pic_sym_p(v) (pic_type(v) == PIC_TT_SYMBOL)
#if defined(__cplusplus)
}
#endif

View File

@ -10,6 +10,7 @@
#include "picrin/string.h"
#include "picrin/proc.h"
#include "picrin/dict.h"
#include "picrin/symbol.h"
struct pic_lib *
pic_open_library(pic_state *pic, pic_value name)

View File

@ -11,6 +11,7 @@
#include "picrin/error.h"
#include "picrin/dict.h"
#include "picrin/cont.h"
#include "picrin/symbol.h"
pic_sym
pic_add_rename(pic_state *pic, struct pic_senv *senv, pic_sym sym)

View File

@ -11,6 +11,7 @@
#include "picrin/blob.h"
#include "picrin/port.h"
#include "picrin/proc.h"
#include "picrin/symbol.h"
static pic_value read(pic_state *pic, struct pic_port *port, int c);
static pic_value read_nullable(pic_state *pic, struct pic_port *port, int c);

View File

@ -15,6 +15,7 @@
#include "picrin/error.h"
#include "picrin/dict.h"
#include "picrin/record.h"
#include "picrin/symbol.h"
#define GET_OPERAND(pic,n) ((pic)->ci->fp[(n)])

View File

@ -11,6 +11,7 @@
#include "picrin/dict.h"
#include "picrin/record.h"
#include "picrin/proc.h"
#include "picrin/symbol.h"
static bool
is_tagged(pic_state *pic, pic_sym tag, pic_value pair)