Module: PatternMatch::KeyMatcher
- Included in:
- Hash
- Defined in:
- lib/pattern-match/experimental.rb
Class Method Summary collapse
Class Method Details
.included(klass) ⇒ Object
26 27 28 29 30 31 32 |
# File 'lib/pattern-match/experimental.rb', line 26 def self.included(klass) class << klass def pattern_matcher(*subpatterns) PatternKeywordArgStyleDeconstructor.new(self, :has_key?, :[], *subpatterns) end end end |