# File lib/hocon/impl/tokens.rb, line 196 def initialize(origin, text) super(TokenType::COMMENT, origin) @text = text end
# File lib/hocon/impl/tokens.rb, line 235 def ==(other) super(other) && other.text == @text end
# File lib/hocon/impl/tokens.rb, line 231 def can_equal(other) other.is_a?(Comment) end
# File lib/hocon/impl/tokens.rb, line 239 def hash hashcode = 41 * (41 + super) hashcode = 41 * (hashcode + @text.hash) hashcode end
# File lib/hocon/impl/tokens.rb, line 223 def to_s sb = StringIO.new sb << "'#" sb << text sb << "' (COMMENT)" sb.string end