diff options
author | NARUSE, Yui <naruse@airemix.jp> | 2021-03-12 00:32:56 +0900 |
---|---|---|
committer | NARUSE, Yui <naruse@airemix.jp> | 2021-03-12 00:32:56 +0900 |
commit | 72c6497453f74f3398130d99fc610922f3995ae5 (patch) | |
tree | fc3cf0a62c26444d74175b4a3e8a389d04ed3642 /ractor.c | |
parent | 6305d1c6edeec2c3aa25b9220142274f1ef2e868 (diff) |
merge revision(s) 7b9476fbfab738d1eb01b4b4c4af9a1680513019: [Backport #17642]
Ractor.allocate should not be allowed
Ractor.allocate and Ractor#dup should not be allowed like Thread.
[Bug #17642]
---
bootstraptest/test_ractor.rb | 18 ++++++++++++++++++
ractor.c | 2 ++
2 files changed, 20 insertions(+)
Diffstat (limited to 'ractor.c')
-rw-r--r-- | ractor.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -2047,6 +2047,8 @@ void Init_Ractor(void) { rb_cRactor = rb_define_class("Ractor", rb_cObject); + rb_undef_alloc_func(rb_cRactor); + rb_eRactorError = rb_define_class_under(rb_cRactor, "Error", rb_eRuntimeError); rb_eRactorIsolationError = rb_define_class_under(rb_cRactor, "IsolationError", rb_eRactorError); rb_eRactorRemoteError = rb_define_class_under(rb_cRactor, "RemoteError", rb_eRactorError); |