[ruby-cvs:73085] mame:r65985 (trunk): lib/rdoc/markup/: Remove wrong call to `=~` against Array

mame at ruby-lang.org mame at ruby-lang.org
Mon Nov 26 14:32:50 JST 2018


mame	2018-11-26 14:32:50 +0900 (Mon, 26 Nov 2018)

  New Revision: 65985

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=65985

  Log:
    lib/rdoc/markup/: Remove wrong call to `=~` against Array
    
    `@res` is an Array, so `@res =~ /\n\z/` calls `Object#=~` which always
    returns nil.
    I guess it should be `@res.last =~ /\n\z/`, but the change causes test
    failures.
    
    This bug was found during work for removal of `Object#=~`.
    [Feature #15231]

  Modified files:
    trunk/lib/rdoc/markup/to_markdown.rb
    trunk/lib/rdoc/markup/to_rdoc.rb


More information about the ruby-cvs mailing list