Ruby 2.4.0 リファレンスマニュアル > ライブラリ一覧 > rexml/documentライブラリ > REXML::Commentクラス > ==

instance method REXML::Comment#==

self == other -> bool[permalink][rdoc]

other と内容(REXML::Comment#string)が同じならば真を返します。