Sha256: c6c99c79cb407767730e911ad16069ef2f323217eb0bef59212321ff227a42a2

Contents?: true

Size: 318 Bytes

Versions: 34

Compression:

Stored size: 318 Bytes

Contents

# frozen_string_literal: true

class Code
  class Node
    class Base8 < Node
      def initialize(parsed)
        return if parsed.blank?

        @base_8 = parsed.presence
      end

      def evaluate(**_args)
        @base_8 ? Object::Integer.new(@base_8.to_i(8)) : Object::Nothing.new
      end
    end
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
code-ruby-0.15.5 lib/code/node/base_8.rb
code-ruby-0.15.4 lib/code/node/base_8.rb
code-ruby-0.15.3 lib/code/node/base_8.rb
code-ruby-0.15.2 lib/code/node/base_8.rb
code-ruby-0.15.0 lib/code/node/base_8.rb
code-ruby-0.14.9 lib/code/node/base_8.rb
code-ruby-0.14.8 lib/code/node/base_8.rb
code-ruby-0.14.6 lib/code/node/base_8.rb
code-ruby-0.14.5 lib/code/node/base_8.rb
code-ruby-0.14.4 lib/code/node/base_8.rb
code-ruby-0.14.3 lib/code/node/base_8.rb
code-ruby-0.14.2 lib/code/node/base_8.rb
code-ruby-0.14.1 lib/code/node/base_8.rb
code-ruby-0.14.0 lib/code/node/base_8.rb