Until we drop 1.9.3 support, we'll save some bytecode by using
[ :literal, :symbols, :in, :arrays ]

In 2.0.0 and later, we may use %i(terser syntax)
---
 lib/yahns/config.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/yahns/config.rb b/lib/yahns/config.rb
index 3055539..f354961 100644
--- a/lib/yahns/config.rb
+++ b/lib/yahns/config.rb
@@ -402,7 +402,7 @@ class Yahns::Config # :nodoc:
       val.close_on_exec = val.sync = true
       val.binmode
     else
-      rt = %w(puts write flush).map(&:to_sym) # match Rack::Lint
+      rt = [ :puts, :write, :flush ] # match Rack::Lint
       rt.all? { |m| val.respond_to?(m) } or raise ArgumentError,
                    "`#{var}' destination must respond to all of: #{rt.inspect}"
     end
-- 
EW


Reply via email to