mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Socket.udp_server_sockets: use symbol proc
Symbol proc is shorter human and machine code; and also avoids needing to name variables. * ext/socket/lib/socket.rb (Socket.udp_server_sockets): use symbol proc git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
e042dd0ee1
commit
abc5e8966c
1 changed files with 1 additions and 1 deletions
|
@ -897,7 +897,7 @@ class Socket < BasicSocket
|
|||
ip_list << ai
|
||||
end
|
||||
}
|
||||
ip_list.uniq!{|e| e.to_sockaddr}
|
||||
ip_list.uniq!(&:to_sockaddr)
|
||||
|
||||
if port == 0
|
||||
sockets = ip_sockets_port0(ip_list, false)
|
||||
|
|
Loading…
Add table
Reference in a new issue