import pprint


def check_overlapping(features):
    """Check for elements of `features` with overlapping ranges. In the
    case of overlap, print an informative error message and return
    names and positions of overlapping features.

    """
    features = features[:]
    overlapping = []
    for i in range(len(features)-1):
        prev_name, prev_start, prev_end = features[i]
        name, start, end = features[i+1]
        if prev_end >= start:
            overlap = ((prev_name, prev_start, prev_end), (name, start, end))
            overlapping.append(overlap)
            raise ValueError('overlapping features: ' + pprint.pformat(overlap))
    return overlapping