lib/kind/basic.rb in kind-5.4.1 vs lib/kind/basic.rb in kind-5.5.0

- old
+ new

@@ -74,6 +74,10 @@ alias_method :respond_to!, :respond_to def value(kind, value, default:) KIND.value(kind, value, of(kind, default)) end + + def or_nil(kind, value) + return value if kind === value + end end