From 85eb93d062934ef711074ec6bd1eaab33fed64aa Mon Sep 17 00:00:00 2001 From: naruse Date: Tue, 7 Dec 2010 11:47:39 +0000 Subject: * ext/nkf/lib/kconv.rb (String#kconv): fix typo and update rdoc. patched by Kouhei Yanagita [ruby-dev:42696] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30112 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/nkf/lib/kconv.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'ext/nkf/lib') diff --git a/ext/nkf/lib/kconv.rb b/ext/nkf/lib/kconv.rb index 6230996876..f8c1ae8f59 100644 --- a/ext/nkf/lib/kconv.rb +++ b/ext/nkf/lib/kconv.rb @@ -51,8 +51,8 @@ module Kconv # call-seq: # Kconv.kconv(str, to_enc, from_enc=nil) # - # Convert str to out_code. - # out_code and in_code are given as constants of Kconv. + # Convert str to to_enc. + # to_enc and from_enc are given as constants of Kconv or Encoding objects. def kconv(str, to_enc, from_enc=nil) opt = '' opt += ' --ic=' + from_enc.to_s if from_enc @@ -199,10 +199,10 @@ class String # call-seq: # String#kconv(to_enc, from_enc) # - # Convert self to out_code. - # out_code and in_code are given as constants of Kconv. + # Convert self to to_enc. + # to_enc and from_enc are given as constants of Kconv or Encoding objects. def kconv(to_enc, from_enc=nil) - form_enc = self.encoding if !from_enc && self.encoding != Encoding.list[0] + from_enc = self.encoding if !from_enc && self.encoding != Encoding.list[0] Kconv::kconv(self, to_enc, from_enc) end -- cgit v1.2.3