remove unused codes
This commit is contained in:
parent
76d06add36
commit
6747792900
|
@ -153,11 +153,8 @@ extern "C" {
|
|||
// useful macros
|
||||
#define IF_INT(val, ifnone) NIL_P(val) ? ifnone : NUM2INT(val)
|
||||
#define IF_DBL(val, ifnone) NIL_P(val) ? ifnone : NUM2DBL(val)
|
||||
#define IF_STRING(str) NIL_P(str) ? NULL : TYPE(str) == T_STRING ? rb
|
||||
#define IF_BOOL(val, t, f, ifnone) val == Qtrue ? t : val == Qfalse ? f : ifnone
|
||||
|
||||
#define IF_DEPTH(val, ifnone) NIL_P(val) ? ifnone : NUM2INT(val)
|
||||
|
||||
#define REGISTER_HASH(hash, str, value) rb_hash_aset(hash, ID2SYM(rb_intern(str)), INT2FIX(value))
|
||||
#define LOOKUP_HASH(hash, key_as_cstr) (rb_hash_lookup(hash, ID2SYM(rb_intern(key_as_cstr))))
|
||||
|
||||
|
|
Loading…
Reference in New Issue