diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2019-08-12 22:41:51 +0900 |
|---|---|---|
| committer | GitHub <[email protected]> | 2019-08-12 22:41:51 +0900 |
| commit | 8a3457c330199960c5c8d1d722f4ca543632ce48 (patch) | |
| tree | 74fbd20c25cf64440b781547cc25c74e9141b804 /src | |
| parent | f113fa2a4fad585521adf0b1d9e9b99836895ab4 (diff) | |
| parent | dfb297e3c4a521fe360c9462dbfc7eafd826f6bf (diff) | |
| download | mruby-8a3457c330199960c5c8d1d722f4ca543632ce48.tar.gz mruby-8a3457c330199960c5c8d1d722f4ca543632ce48.zip | |
Merge pull request #4629 from shuujii/mrb_str_pool-can-embed-one-more-byte
`mrb_str_pool` can embed one more byte; ref #4626
Diffstat (limited to 'src')
| -rw-r--r-- | src/state.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/state.c b/src/state.c index e5e0161bf..69b069304 100644 --- a/src/state.c +++ b/src/state.c @@ -170,7 +170,7 @@ mrb_str_pool(mrb_state *mrb, mrb_value str) len = s->as.heap.len; } - if (len < RSTRING_EMBED_LEN_MAX) { + if (RSTR_EMBEDDABLE_P(len)) { RSTR_SET_EMBED_FLAG(ns); RSTR_SET_EMBED_LEN(ns, len); if (ptr) { |
