Last active
December 26, 2016 16:28
-
-
Save kirkgo/b587d9baf55e95667595 to your computer and use it in GitHub Desktop.
Revisions
-
kirkgo revised this gist
Dec 26, 2016 . No changes.There are no files selected for viewing
-
Kirk Patrick revised this gist
Sep 27, 2011 . 1 changed file with 2 additions and 4 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,16 +1,14 @@ class String alias_method :old_upcase, :upcase def upcase self.gsub( /\303[\240-\277]/ ) do |match| match[0].chr + (match[1] - 040).chr end.old_upcase end alias_method :old_downcase, :downcase def downcase self.gsub( /\303[\200-\237]/ ) do |match| match[0].chr + (match[1] + 040).chr end.old_downcase end -
Kirk Patrick created this gist
Sep 27, 2011 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,17 @@ class String alias_method :old_upcase, :upcase def upcase self.gsub( /\303[\240-\277]/ ) do |match| match[0].chr + (match[1] - 040).chr end.old_upcase end alias_method :old_downcase, :downcase def downcase self.gsub( /\303[\200-\237]/ ) do |match| match[0].chr + (match[1] + 040).chr end.old_downcase end end