nodes: 0, module; 1, function_definition; 2, function_name:_get_mro; 3, parameters; 4, block; 5, identifier:cls; 6, expression_statement; 7, if_statement; 8, return_statement; 9, comment:"""
      Returns the bases classes for cls sorted by the MRO.
  
      Works around an issue on Jython where inspect.getmro will not return all
      base classes if multiple classes share the same name. Instead, this
      function will return a tuple containing the class itself, and the contents
      of cls.__bases__. See https://github.com/pypa/setuptools/issues/1024.
      """; 10, comparison_operator:platform.python_implementation() == "Jython"; 11, block; 12, call; 13, call; 14, string:"Jython"; 15, return_statement; 16, attribute; 17, argument_list; 18, attribute; 19, argument_list; 20, binary_operator:(cls,) + cls.__bases__; 21, identifier:inspect; 22, identifier:getmro; 23, identifier:cls; 24, identifier:platform; 25, identifier:python_implementation; 26, tuple; 27, attribute; 28, identifier:cls; 29, identifier:cls; 30, identifier:__bases__
code: def _get_mro(cls):
      """
      Returns the bases classes for cls sorted by the MRO.
  
      Works around an issue on Jython where inspect.getmro will not return all
      base classes if multiple classes share the same name. Instead, this
      function will return a tuple containing the class itself, and the contents
      of cls.__bases__. See https://github.com/pypa/setuptools/issues/1024.
      """
      if platform.python_implementation() == "Jython":
          return (cls,) + cls.__bases__
      return inspect.getmro(cls)