diff --git a/ChangeLog b/ChangeLog index 27d4bd3fdf..3b7611663b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,6 +6,13 @@ Sun Oct 22 16:47:56 2006 Nobuyoshi Nakada * strnig.c (rb_str_new4): keep shared string untainted when orignal string is tainted. fixed: [ruby-dev:29672] +Sun Oct 22 07:55:11 2006 Yukihiro Matsumoto + + * string.c (rb_str_upcase, rb_str_downcase, rb_str_downcase, + rb_str_upcase_bang, rb_str_downcase_bang, rb_str_swapcase_bang): + add RDoc description that case conversion to be effective only + in ASCII region. + Sat Oct 21 17:50:40 2006 Akinori MUSHA * ext/digest/lib/digest.rb: Follow the framework updates. diff --git a/string.c b/string.c index 39bae6d63d..529c375b4f 100644 --- a/string.c +++ b/string.c @@ -2711,6 +2711,7 @@ rb_str_dump(VALUE str) * * Upcases the contents of str, returning nil if no changes * were made. + * Note: case replacement is effective only in ASCII region. */ static VALUE @@ -2744,6 +2745,7 @@ rb_str_upcase_bang(VALUE str) * Returns a copy of str with all lowercase letters replaced with their * uppercase counterparts. The operation is locale insensitive---only * characters ``a'' to ``z'' are affected. + * Note: case replacement is effective only in ASCII region. * * "hEllO".upcase #=> "HELLO" */ @@ -2763,6 +2765,7 @@ rb_str_upcase(VALUE str) * * Downcases the contents of str, returning nil if no * changes were made. + * Note: case replacement is effective only in ASCII region. */ static VALUE @@ -2796,6 +2799,7 @@ rb_str_downcase_bang(VALUE str) * Returns a copy of str with all uppercase letters replaced with their * lowercase counterparts. The operation is locale insensitive---only * characters ``A'' to ``Z'' are affected. + * Note: case replacement is effective only in ASCII region. * * "hEllO".downcase #=> "hello" */ @@ -2815,6 +2819,7 @@ rb_str_downcase(VALUE str) * * Modifies str by converting the first character to uppercase and the * remainder to lowercase. Returns nil if no changes are made. + * Note: case conversion is effective only in ASCII region. * * a = "hello" * a.capitalize! #=> "Hello" @@ -2855,6 +2860,7 @@ rb_str_capitalize_bang(VALUE str) * * Returns a copy of str with the first character converted to uppercase * and the remainder to lowercase. + * Note: case conversion is effective only in ASCII region. * * "hello".capitalize #=> "Hello" * "HELLO".capitalize #=> "Hello" @@ -2876,6 +2882,7 @@ rb_str_capitalize(VALUE str) * * Equivalent to String#swapcase, but modifies the receiver in * place, returning str, or nil if no changes were made. + * Note: case conversion is effective only in ASCII region. */ static VALUE @@ -2912,6 +2919,7 @@ rb_str_swapcase_bang(VALUE str) * * Returns a copy of str with uppercase alphabetic characters converted * to lowercase and lowercase characters converted to uppercase. + * Note: case conversion is effective only in ASCII region. * * "Hello".swapcase #=> "hELLO" * "cYbEr_PuNk11".swapcase #=> "CyBeR_pUnK11"