class RBS::AST::Declarations::Constant

def ==(other)

def ==(other)
  other.is_a?(Constant) &&
    other.name == name &&
    other.type == type
end

def hash

def hash
  self.class.hash ^ name.hash ^ type.hash
end

def initialize(name:, type:, location:, comment:, annotations: [])

def initialize(name:, type:, location:, comment:, annotations: [])
  @name = name
  @type = type
  @location = location
  @comment = comment
  @annotations = annotations || []
end

def to_json(state = _ = nil)

def to_json(state = _ = nil)
  {
    declaration: :constant,
    name: name,
    type: type,
    location: location,
    comment: comment
  }.to_json(state)
end