From 6d86db32a66a05fd15eb4a6ca7cd46d322deb13a Mon Sep 17 00:00:00 2001 From: Pavel Koneski Date: Sat, 7 Mar 2020 17:04:52 -0800 Subject: [PATCH] Remove automatic conversion from string to ByteArray in Binder --- .../Runtime/Binding/ConversionBinder.cs | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/Src/IronPython/Runtime/Binding/ConversionBinder.cs b/Src/IronPython/Runtime/Binding/ConversionBinder.cs index 6c69deac4..b5f47559d 100644 --- a/Src/IronPython/Runtime/Binding/ConversionBinder.cs +++ b/Src/IronPython/Runtime/Binding/ConversionBinder.cs @@ -170,20 +170,7 @@ internal DynamicMetaObject FallbackConvert(Type returnType, DynamicMetaObject se // Interface conversion helpers... if (genTo == typeof(IList<>)) { - if (self.LimitType == typeof(string)) { - res = new DynamicMetaObject( - Ast.Call( - typeof(PythonOps).GetMethod(nameof(PythonOps.MakeByteArray)), - AstUtils.Convert(self.Expression, typeof(string)) - ), - BindingRestrictions.GetTypeRestriction( - self.Expression, - typeof(string) - ) - ); - } else { - res = TryToGenericInterfaceConversion(self, type, typeof(IList), typeof(ListGenericWrapper<>)); - } + res = TryToGenericInterfaceConversion(self, type, typeof(IList), typeof(ListGenericWrapper<>)); } else if (genTo == typeof(IDictionary<,>)) { res = TryToGenericInterfaceConversion(self, type, typeof(IDictionary), typeof(DictionaryGenericWrapper<,>)); } else if (genTo == typeof(IEnumerable<>)) {