This function is only used by the servers. Except... it is wrapped with this code:
if socket.is_a? TCPSocket
Obviously, TCPSocket refers to C::IO::TCPSocket and not to ::TCPSocket. In the both servers' contexts, things to optimize are: Celluloid::IO::TCPServer. C::IO::TCPServer is not a C::IO::TCPSocket, nor it subclasses one, so the code never evaluates.
After some talk with @tarcieri on IRC, he told me, that the function doesn't make sense on a listener (ie. server) socket. And it isn't used in any other context.
This function is only used by the servers. Except... it is wrapped with this code:
Obviously, TCPSocket refers to C::IO::TCPSocket and not to ::TCPSocket. In the both servers' contexts, things to optimize are: Celluloid::IO::TCPServer. C::IO::TCPServer is not a C::IO::TCPSocket, nor it subclasses one, so the code never evaluates.
After some talk with @tarcieri on IRC, he told me, that the function doesn't make sense on a listener (ie. server) socket. And it isn't used in any other context.
Thus, the pull request just removes unused code.