-
Notifications
You must be signed in to change notification settings - Fork 167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make bn shareable when frozen #808
Conversation
e2736f6
to
cc4fd69
Compare
Could you make the part that changes |
cc4fd69
to
5a77cc5
Compare
5a77cc5
to
bed9067
Compare
@rhenium done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#initialize
also needs a frozen check.
Could you add a test case to ensure freezing it actually makes it shareable?
eab2629
to
3472aa3
Compare
why and where? 🤔 added a test. |
|
3472aa3
to
d3c8e66
Compare
gotcha, added. One question though: is it worth it, considering that on intialize, the object isn't expected to be frozen? What would that guard against? |
It's needed because it's callable from Ruby, especially if the object is now expected to be thread safe when frozen. Whether calling |
It looks good to me now. Thanks! |
added frozen check on every state change.