This method is deprecated or moved on the latest stable version.
The last existing version (v2.1.0) is shown here.
consumes?(str)
public
Checks if the string is valid UTF8.
# File activesupport/lib/active_support/multibyte/handlers/utf8_handler.rb, line 342
def consumes?(str)
# Unpack is a little bit faster than regular expressions
begin
str.unpack('U*')
true
rescue ArgumentError
false
end
end