Sha256: 2cf032c1b28a74cae2ecab782ab5298212e17278fd674b561bfc97d7bf4afe87

Contents?: true

Size: 488 Bytes

Versions: 5

Compression:

Stored size: 488 Bytes

Contents

module Alf
  class Predicate
    module Native
      include Expr

      def priority
        90
      end

      def proc
        self[1]
      end

      def to_ruby_code(scope = 't')
        if proc.respond_to?(:source_code)
          code = proc.source_code
          return code if code
        end
        raise NotSupportedError
      end

      def to_proc(scope = 't')
        proc
      end

      def free_variables
        raise NotSupportedError
      end

    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
alf-core-0.16.3 lib/alf/predicate/nodes/native.rb
alf-core-0.16.2 lib/alf/predicate/nodes/native.rb
alf-core-0.16.1 lib/alf/predicate/nodes/native.rb
alf-core-0.16.0 lib/alf/predicate/nodes/native.rb
alf-core-0.15.0 lib/alf/predicate/nodes/native.rb