celluloid/reel — pull request #158 by czaks (2014-08-09 03:33:53+00:00)
Title: Remove optimize function

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.

Thus, the pull request just removes unused code.