ArgumentError works for both MRI and JRuby.