Sha256: b055ac0e1c33cfd41d41e0e5fdd86a1e943f42d34a15e9edee50e0843fb0a120
Contents?: true
Size: 831 Bytes
Versions: 26
Compression:
Stored size: 831 Bytes
Contents
Foobara.require_project_file("type_declarations", "desugarizer") module Foobara module TypeDeclarations module Handlers class RegisteredTypeDeclaration < TypeDeclarationHandler # TODO: make a quick way to convert a couple simple procs into a transformer class SymbolDesugarizer < TypeDeclarations::Desugarizer def applicable?(sugary_type_declaration) sugary_type_declaration.is_a?(Symbol) && type_registered?(sugary_type_declaration) end def desugarize(symbol) # TODO: just use the symbol and nothing else?? # maybe confusing in languages with no distinction between symbol and string? { type: symbol } end def priority Priority::FIRST end end end end end end
Version data entries
26 entries across 26 versions & 1 rubygems