def get_encoded_len_fn(typename):
    """
    Get the name of a function which can retrieve the encoded length of a type
    """
    assert typename[:4] == "sbp_"
    assert typename[-2:] == "_t"
    return typename[:-2] + "_encoded_len"