bool HeaderTable::operator==(const HeaderTable& other) const {
  if (size() != other.size()) {
    return false;
  }
  if (bytes() != other.bytes()) {
    return false;
  }
  list<uint32_t> refset = referenceSet();
  refset.sort();
  list<uint32_t> otherRefset = other.referenceSet();
  otherRefset.sort();
  if (refset != otherRefset) {
    return false;
  }
  return true;
}
bool HeaderTable::operator==(const HeaderTable& other) const {
  if (size() != other.size()) {
    return false;
  }
  if (bytes() != other.bytes()) {
    return false;
  }
  list<uint32_t> refset = referenceSet();
  refset.sort();
  list<uint32_t> otherRefset = other.referenceSet();
  otherRefset.sort();
  if (refset != otherRefset) {
    return false;
  }
  return true;
}