diff options
| author | Yukihiro Matsumoto <[email protected]> | 2012-08-14 13:16:34 +0900 |
|---|---|---|
| committer | Yukihiro Matsumoto <[email protected]> | 2012-08-14 13:16:34 +0900 |
| commit | 7d02df3016b0c6eb3f4ee945198772cf4ebca3fa (patch) | |
| tree | af4c35ee567e9be3e2ef6ca0c34dbd10440550bc /include/mrbconf.h | |
| parent | e74600c919cdadab1b4e605e50181f8cdafe7ab3 (diff) | |
| download | mruby-7d02df3016b0c6eb3f4ee945198772cf4ebca3fa.tar.gz mruby-7d02df3016b0c6eb3f4ee945198772cf4ebca3fa.zip | |
NaN boxing
Diffstat (limited to 'include/mrbconf.h')
| -rw-r--r-- | include/mrbconf.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/include/mrbconf.h b/include/mrbconf.h index 693e7da88..e308e8f82 100644 --- a/include/mrbconf.h +++ b/include/mrbconf.h @@ -13,6 +13,12 @@ /* add -DMRB_USE_FLOAT to use float instead of double for floating point numbers */ //#define MRB_USE_FLOAT +/* represent mrb_value in boxed double; conflict with MRB_USE_FLOAT */ +//#define MRB_NAN_BOXING + +/* define on big endian machines; used by MRB_NAN_BOXING */ +//#define MRB_ENDIAN_BIG + /* argv max size in mrb_funcall */ //#define MRB_FUNCALL_ARGC_MAX 16 @@ -54,8 +60,13 @@ typedef double mrb_float; #endif #define readfloat(p) (mrb_float)strtod((p),NULL) +#ifdef MRB_NAN_BOXING +typedef int32_t mrb_int; +typedef int32_t mrb_sym; +#else typedef int mrb_int; typedef intptr_t mrb_sym; +#endif /* define ENABLE_XXXX from DISABLE_XXX */ #ifndef DISABLE_REGEXP |
