def file_map(fdata: Callable) -> tuple:
    """Build file sequence and sort it by absolute position."""
    new_sections = []
    chrono, nxt, nb = build_xref_sequence(fdata)
    index = build_index_from_xref_sequence(chrono, nxt, nb)
    sections = file_object_map(fdata)
    for x in sections:
        if x[2] == 'VOID':
            continue
        new_sections.append(x)
    return (new_sections, index)
Build file sequence and sort it by absolute position.
pdfsyntax/cli.py