def indicate_last(items):
    """
    iterate through list and indicate which item is the last, intended to
    assist tree displays of hierarchical content.

    :return: yielding (<bool>, <item>) where bool is True only on last entry
    :rtype: generator
    """
    last_index = len(items) - 1
    for i, item in enumerate(items):
        yield i == last_index, item
