Sha256: cbc57f26f3002585149abeaec1a5e8299254dc2e6a00b3cce76289c621083ba7
Contents?: true
Size: 738 Bytes
Versions: 26
Compression:
Stored size: 738 Bytes
Contents
Foobara.require_project_file("type_declarations", "handlers/registered_type_declaration") module Foobara module TypeDeclarations module Handlers class ExtendRegisteredTypeDeclaration < RegisteredTypeDeclaration def applicable?(sugary_type_declaration) strict_type_declaration = desugarize(sugary_type_declaration) return false unless strict_type_declaration.is_a?(::Hash) # if there's no processors to extend the existing type with, then we don't handle that here return false if strict_type_declaration.keys == [:type] super(strict_type_declaration.slice(:type)) end def priority Priority::LOWEST end end end end end
Version data entries
26 entries across 26 versions & 1 rubygems