Sha256: 6d10e943ed994f536d9a35761cb54bdbe12d800be0e43b2c2196d232708fc956

Contents?: true

Size: 358 Bytes

Versions: 2

Compression:

Stored size: 358 Bytes

Contents

module Finitio
  module Syntax
    module SubType

      def compile(factory)
        s = rel_type.compile(factory)
        c = constraint_def.compile(factory)
        factory.subtype(s, c)
      end

      def to_ast
        [:sub_type, rel_type.to_ast] + constraint_def.to_ast
      end

    end # module SubType
  end # module Syntax
end # module Finitio

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
finitio-0.4.1 lib/finitio/syntax/sub_type.rb
finitio-0.4.0 lib/finitio/syntax/sub_type.rb