diff options
author | tenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-04-17 03:17:25 +0000 |
---|---|---|
committer | tenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-04-17 03:17:25 +0000 |
commit | 3c55b643aec09bbe779dab25b2397947eded2b9b (patch) | |
tree | d7705428a035cd7c4384a0e34d59415bf3de9ca4 /gc.h | |
parent | fcd679ed11e3e801431f2f931dbe925edb8df0bf (diff) |
Adding `GC.compact` and compacting GC support.
This commit adds the new method `GC.compact` and compacting GC support.
Please see this issue for caveats:
https://bugs.ruby-lang.org/issues/15626
[Feature #15626]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67576 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'gc.h')
-rw-r--r-- | gc.h | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -57,6 +57,10 @@ rb_gc_debug_body(const char *mode, const char *msg, int st, void *ptr) #define RUBY_GC_INFO if(0)printf #endif +#define RUBY_MARK_NO_PIN_UNLESS_NULL(ptr) do { \ + VALUE markobj = (ptr); \ + if (RTEST(markobj)) {rb_gc_mark_no_pin(markobj);} \ +} while (0) #define RUBY_MARK_UNLESS_NULL(ptr) do { \ VALUE markobj = (ptr); \ if (RTEST(markobj)) {rb_gc_mark(markobj);} \ |