Change namespace of IO::Buffer to Coolio::Buffer#82
Change namespace of IO::Buffer to Coolio::Buffer#82ioquatix merged 4 commits intosocketry:masterfrom
Conversation
The `IO::Buffer` class was introduced at Ruby 3.1. Ref: https://bugs.ruby-lang.org/issues/18020 The cool.io gem has same name class and it has been conflicted. If you used unknowingly, it will overwrite Ruby's IO::Buffer and it might cause problems. So, this patch will add namespece that it can be used as `Coolio::IO::Buffer`.
|
@ioquatix Could you please review this PR? Thanks |
|
I'm okay with this, but to avoid the namespace confusion, what do you think about renaming it to Using Imagine this code: class MyThing
include Coolio
def open
IO.open(...) # This would now refer to `Coolio::IO`
end
end |
|
@ioquatix Thank you for your review. Thanks. |
ioquatix
left a comment
There was a problem hiding this comment.
This looks great to me, thanks for your effort and implementing the requested changes.
|
I suppose we can make a minor release for this change. |
|
I've released v1.9.0 do you mind testing it and letting me know how it is? |
|
Thank you!! If it works as expected, all tests will be successful. |
The
IO::Bufferclass was introduced at Ruby 3.1.Ref: https://bugs.ruby-lang.org/issues/18020
The cool.io gem has same name class and it has been conflicted. If you used unknowingly, it will overwrite Ruby's IO::Buffer and it might cause problems.
So, this patch will add namespece that it can be used as
Coolio::Buffer.Related to fluent/fluentd#4619
Types of Changes
Contribution