code: def _setup(self):
          
  
          cls = self.__class__
          cls._field_map = {}
          cls._field_ids = []
          cls._precomputed_specs = []
          for index, field in enumerate(cls._fields):
              if len(field) < 3:
                  field = field + ({},)
                  cls._fields[index] = field
              cls._field_map[field[0]] = index
              cls._field_ids.append(_build_id_tuple(field[2], field[1]))
  
          if cls._oid_pair is not None:
              cls._oid_nums = (cls._field_map[cls._oid_pair[0]], cls._field_map[cls._oid_pair[1]])
  
          for index, field in enumerate(cls._fields):
              has_callback = cls._spec_callbacks is not None and field[0] in cls._spec_callbacks
              is_mapped_oid = cls._oid_nums is not None and cls._oid_nums[1] == index
              if has_callback or is_mapped_oid:
                  cls._precomputed_specs.append(None)
              else:
                  cls._precomputed_specs.append((field[0], field[1], field[1], field[2], None))
docs: Generates _field_map, _field_ids and _oid_nums for use in parsing