const fn subgroup_id_mode_must_be_consulted(draft: DraftVersion) -> boolExpand description
Whether a header’s reserved subgroup-ID mode has to be told apart from mode 1 before an object behind it can be judged. Drafts 15-20.
Not the drafts that name a SUBGROUP_ID_MODE field, which is neither a superset nor a subset of this. Drafts 16 through 20 name one — draft-16: “Type values with SUBGROUP_ID_MODE set to 0b11: 0x16, 0x17, 0x1E, 0x1F, 0x36, 0x37, 0x3E, 0x3F. This mode is reserved for future use.” Draft-15 names nothing and states the same three carriers as table columns, then leaves the fourth combination out of the table. The wording is what differs; the two bits and their four values are not.
What decides it is where AnySubgroupHeader::subgroup_id answers None
for more than one reason. On these five it answers None for both mode 1
and the fourth combination, so None alone cannot say whether the first
object defines the subgroup or the header is one no receiver should read,
and the mode has to be consulted. Drafts 11 through 14 give each carrier a
stream type of its own and assign every type they define, so their None
means the first object and nothing else; drafts 07-10 always put the ID on
the wire and never answer None at all.
Both were outside this set while the codec still resolved their fourth
combination to a subgroup ID — draft-15 to zero by falling through, draft-16
to whatever varint it went on to read — and being outside it was right then,
because a None from those two really did mean mode 1 and nothing else. The
codec now answers None for both readings, as it always did on 17-20, so
the sentence above is what picks the drafts rather than a list of the ones
that name a field.
Exhaustive rather than a matches!, because the question this asks is not
one a new draft can be assumed out of: the sentence above is about what
AnySubgroupHeader::subgroup_id answers None for on that draft, and only
reading the draft settles it.