This project is archived and is in readonly mode.
#ord method for ActiveSupport::Multibyte::Chars
Reported by Jason Cheow | November 26th, 2008 @ 03:15 PM
This patch adds a ActiveSupport::Multibyte::Chars#ord method so that it returns correct Unicode value instead of falling back on String#ord in CoreExtensions, which is not multibyte compatible.
Before patch:
'こんにちは'.mb_chars.ord #=> 227
After patch:
'こんにちは'.mb_chars.ord #=> 12371
Comments and changes to this ticket
-
Jason Cheow November 26th, 2008 @ 03:15 PM
- Title changed from #ord for ActiveSupport::Multibyte::Chars to #ord method for ActiveSupport::Multibyte::Chars
-
Jeremy Kemper November 26th, 2008 @ 06:41 PM
- Milestone cleared.
- State changed from new to open
- Assigned user set to Jeremy Kemper
-
Repository December 9th, 2008 @ 12:12 AM
- State changed from open to committed
(from [4e60eebae05aeec65e4894e3901c9d61c9b32910]) Add ActiveSupport::Multibyte::Chars#ord method so that it returns correct Unicode value instead of falling back on String#ord in CoreExtensions, which is not multibyte compatible
[#1483 state:committed]
Signed-off-by: Jeremy Kemper jeremy@bitsweat.net http://github.com/rails/rails/co...
-
Repository December 9th, 2008 @ 12:12 AM
(from [032902146a6ff8a194901ba91cd4d6b00b9eb411]) Add ActiveSupport::Multibyte::Chars#ord method so that it returns correct Unicode value instead of falling back on String#ord in CoreExtensions, which is not multibyte compatible
[#1483 state:committed]
Signed-off-by: Jeremy Kemper jeremy@bitsweat.net http://github.com/rails/rails/co...
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
People watching this ticket
Attachments
Tags
Referenced by
- 1483 #ord method for ActiveSupport::Multibyte::Chars [#1483 state:committed]
- 1483 #ord method for ActiveSupport::Multibyte::Chars [#1483 state:committed]