From: "john_firebaugh (John Firebaugh)" Date: 2012-03-23T10:34:50+09:00 Subject: [ruby-core:43567] [ruby-trunk - Bug #6192] Integer() doesn't handle UTF-16 input Issue #6192 has been updated by john_firebaugh (John Firebaugh). Related, String#to_i: >> "2007".encode("UTF-16le").to_i => 2 ---------------------------------------- Bug #6192: Integer() doesn't handle UTF-16 input https://bugs.ruby-lang.org/issues/6192#change-25060 Author: john_firebaugh (John Firebaugh) Status: Open Priority: Normal Assignee: Category: Target version: ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-darwin11.3.0] >> Integer("2007".encode("UTF-16le")) ArgumentError: string contains null byte from (irb):209:in `Integer' from (irb):209 from /Users/john/.rvm/rubies/ruby-1.9.3-p125/bin/irb:16:in `
' -- http://bugs.ruby-lang.org/