From 32708887c48861b65873c8fd60e47f8bb3fd6417 Mon Sep 17 00:00:00 2001 From: "Liana.Bakradze" Date: Tue, 30 May 2017 13:31:32 +0300 Subject: [PATCH] inline function (PY-21763) --- python/helpers/pydev/_pydevd_bundle/pydevd_vars.py | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/python/helpers/pydev/_pydevd_bundle/pydevd_vars.py b/python/helpers/pydev/_pydevd_bundle/pydevd_vars.py index ed693bc35674..2e896252409b 100644 --- a/python/helpers/pydev/_pydevd_bundle/pydevd_vars.py +++ b/python/helpers/pydev/_pydevd_bundle/pydevd_vars.py @@ -414,19 +414,13 @@ def change_attr_expression(thread_id, frame_id, attr, expression, dbg, value=SEN MAXIMUM_ARRAY_SIZE = 100 -def array_to_xml_converter(array, name, roffset, coffset, rows, cols, format): - array, metaxml, r, c, f = array_to_meta_xml(array, name, format) - xml = metaxml +def array_to_xml(array, name, roffset, coffset, rows, cols, format): + array, xml, r, c, f = array_to_meta_xml(array, name, format) format = '%' + f if rows == -1 and cols == -1: rows = r cols = c - xml += array_to_xml(array, roffset, coffset, rows, cols, format) - return xml - -def array_to_xml(array, roffset, coffset, rows, cols, format): - xml = "" rows = min(rows, MAXIMUM_ARRAY_SIZE) cols = min(cols, MAXIMUM_ARRAY_SIZE) @@ -616,7 +610,7 @@ def header_data_to_xml(rows, cols, dtypes, col_bounds, col_to_format, df, dim): xml += "\n" return xml -TYPE_TO_XML_CONVERTERS = {"ndarray": array_to_xml_converter, "DataFrame": dataframe_to_xml, "Series": dataframe_to_xml} +TYPE_TO_XML_CONVERTERS = {"ndarray": array_to_xml, "DataFrame": dataframe_to_xml, "Series": dataframe_to_xml} def table_like_struct_to_xml(array, name, roffset, coffset, rows, cols, format):