Sha256: a5f7c307acf1edd6ce4a6d570c44bb2ff68c78bb120a1c0181d892bd48d09443

Contents?: true

Size: 216 Bytes

Versions: 7

Compression:

Stored size: 216 Bytes

Contents

# frozen_string_literal: true

# @api public
# @since 0.1.0
SmartCore::Types::Value.define_type(:Symbol) do |type|
  type.define_checker do |value|
    value.is_a?(::Symbol)
  end

  type.define_caster(&:to_sym)
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
smart_types-0.1.0.alpha6 lib/smart_core/types/value/symbol.rb
smart_types-0.1.0.alpha5 lib/smart_core/types/value/symbol.rb
smart_types-0.1.0.alpha4 lib/smart_core/types/value/symbol.rb
smart_types-0.1.0.alpha3 lib/smart_core/types/value/symbol.rb
smart_types-0.1.0.alpha2 lib/smart_core/types/value/symbol.rb
smart_types-0.1.0.alpha lib/smart_core/types/value/symbol.rb
smart_types-0.0.0 lib/smart_core/types/value/symbol.rb