darthjee/danica

View on GitHub
lib/danica/wrapper/container.rb

Summary

Maintainability
A
0 mins
Test Coverage
A
100%
# frozen_string_literal: true

module Danica
  class Wrapper::Container
    include Common
    attr_accessor :content

    delegate :to_f, :contentd?, :to, :to_tex, :to_gnu, :priority, :grouped?,
             :signaled?, :constant?, :valued?, :*, :+, :-, :/, :**, :-@,
             :variables, :variable?, to: :content

    default_value :container?, true

    def initialize(content)
      @content = content
    end

    def ==(other)
      return content == other unless other.is_a?(self.class)

      content == other.content
    end
  end
end