зеркало из https://github.com/github/ruby.git
symbol.h: move macros
* symbol.h (RSYMBOL): move macros for Symbol from internal.h. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47018 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
5b0ccdbc67
Коммит
6016da7dab
|
@ -418,10 +418,6 @@ struct RSymbol {
|
|||
ID type;
|
||||
};
|
||||
|
||||
#define RSYMBOL(obj) (R_CAST(RSymbol)(obj))
|
||||
#define SYMBOL_PINNED FL_USER1
|
||||
#define SYMBOL_PINNED_P(sym) FL_TEST((sym), SYMBOL_PINNED)
|
||||
|
||||
struct RFloat {
|
||||
struct RBasic basic;
|
||||
double float_value;
|
||||
|
|
4
symbol.h
4
symbol.h
|
@ -14,6 +14,10 @@
|
|||
|
||||
#include "id.h"
|
||||
|
||||
#define RSYMBOL(obj) (R_CAST(RSymbol)(obj))
|
||||
#define SYMBOL_PINNED FL_USER1
|
||||
#define SYMBOL_PINNED_P(sym) FL_TEST((sym), SYMBOL_PINNED)
|
||||
|
||||
#define ID_DYNAMIC_SYM_P(id) (!(id&ID_STATIC_SYM)&&id>tLAST_OP_ID)
|
||||
#define STATIC_SYM2ID(sym) RSHIFT((unsigned long)(sym), RUBY_SPECIAL_SHIFT)
|
||||
#define STATIC_ID2SYM(id) (((VALUE)(id)<<RUBY_SPECIAL_SHIFT)|SYMBOL_FLAG)
|
||||
|
|
Загрузка…
Ссылка в новой задаче