# File lib/pathutil.rb, line 420
  def sub_ext(ext)
    self.class.new(@path.chomp(File.extname(@path)) + ext)
  end