diff options
| author | Yukihiro Matsumoto <[email protected]> | 2012-09-12 07:40:38 +0900 |
|---|---|---|
| committer | Yukihiro Matsumoto <[email protected]> | 2012-09-12 07:40:38 +0900 |
| commit | cdbd116c49078ab32d70f6a0f8cf9dcfa694a7a3 (patch) | |
| tree | 1cfd1968cd0407a9bf84989be7cdd6b7ab492747 /src/string.c | |
| parent | 2edee29e685d51ddd5ba2cc4b80f93eaa33ae40f (diff) | |
| parent | bcd77200ac829311c745d260053ee9a3ec5d1f16 (diff) | |
| download | mruby-cdbd116c49078ab32d70f6a0f8cf9dcfa694a7a3.tar.gz mruby-cdbd116c49078ab32d70f6a0f8cf9dcfa694a7a3.zip | |
Merge branch 'master' of github.com:mruby/mruby
Diffstat (limited to 'src/string.c')
| -rw-r--r-- | src/string.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/string.c b/src/string.c index a454aab97..d8fe56790 100644 --- a/src/string.c +++ b/src/string.c @@ -2598,7 +2598,10 @@ mrb_cstr_to_dbl(mrb_state *mrb, const char * p, int badcheck) double d; // const char *ellipsis = ""; // int w; -#define DBL_DIG 16 +#if !defined(DBL_DIG) + #define DBL_DIG 16 +#endif + enum {max_width = 20}; #define OutOfRange() (((w = end - p) > max_width) ? \ (w = max_width, ellipsis = "...") : \ |
