def _list_itemstrs(list_, **kwargs):
items = list(list_)<EOL>kwargs['<STR_LIT>'] = True<EOL>_tups = [repr2(item, **kwargs) for item in items]<EOL>itemstrs = [t[<NUM_LIT:0>] for t in _tups]<EOL>max_height = max([t[<NUM_LIT:1>]['<STR_LIT>'] for t in _tups]) if _tups else <NUM_LIT:0><EOL>_leaf_info = {<EOL>'<STR_LIT>': max_height + <NUM_LIT:1>,<EOL>}<EOL>sort = kwargs.get('<STR_LIT>', None)<EOL>if sort is None:<EOL><INDENT>sort = isinstance(list_, (set, frozenset))<EOL><DEDENT>if sort:<EOL><INDENT>itemstrs = _sort_itemstrs(items, itemstrs)<EOL><DEDENT>return itemstrs, _leaf_info<EOL>
Create a string representation for each item in a list.