mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
gc.c: use RUBY_DEFAULT_FREE instead of open-coded constant
Improves readability and makes future changes easier git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63486 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
0a4be5beda
commit
2be65894e1
1 changed files with 1 additions and 1 deletions
2
gc.c
2
gc.c
|
@ -2978,7 +2978,7 @@ rb_objspace_call_finalizer(rb_objspace_t *objspace)
|
|||
if (RTYPEDDATA_P(p)) {
|
||||
RDATA(p)->dfree = RANY(p)->as.typeddata.type->function.dfree;
|
||||
}
|
||||
if (RANY(p)->as.data.dfree == (RUBY_DATA_FUNC)-1) {
|
||||
if (RANY(p)->as.data.dfree == RUBY_DEFAULT_FREE) {
|
||||
xfree(DATA_PTR(p));
|
||||
}
|
||||
else if (RANY(p)->as.data.dfree) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue