FIRST_RUBY_WITHOUT_ICONV = '1.9' require 'iconv' if RUBY_VERSION < FIRST_RUBY_WITHOUT_ICONV module Findr # Class for wrapping original exceptions, which could be from Iconv (Ruby 1.8) # or String (Ruby >=1.9). # () class Error < ::StandardError attr_reader :original def initialize(msg, original=$!) super(msg) @original = original; end end # Wrapper class for String#encode (Ruby >=1.9) and Iconv#iconv (Ruby 1.8). class Encoder class Error < Findr::Error; end class <