Method: Jet::Type.with
- Defined in:
- lib/jet/type.rb
.with(type, *types, name: nil, &blk) ⇒ Object
9 10 11 12 13 14 15 16 17 18 |
# File 'lib/jet/type.rb', line 9 def self.with(type, *types, name: nil, &blk) Jet.type_check!("`type`", type, Type) new( name || type.name, *[type.types, types].flatten.uniq, coercions: type.coercions, filter: type.filter, &blk ) end |