Sha256: 746b8e5c498dce13e5f7031fa8bc9b5278d575c8f6be51bf8e6c83fa2becb009

Contents?: true

Size: 514 Bytes

Versions: 1

Compression:

Stored size: 514 Bytes

Contents

module Polyfill
  module V2_4
    module Symbol
      module Instance
        module Match
          module Method
            def match(*args)
              if block_given?
                to_s.match(*args, &::Proc.new)
              else
                to_s.match(*args)
              end
            end
          end

          refine ::Symbol do
            include Method
          end

          def self.included(base)
            base.include Method
          end
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
polyfill-0.6.0 lib/polyfill/v2_4/symbol/instance/match.rb