ObjFW  Diff

Differences From Artifact [b658da002c]:

To Artifact [21ee30041a]:


803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
- (uint32_t)hash
{
	uintptr_t ptr = (uintptr_t)self;
	uint32_t hash;

	OF_HASH_INIT(hash);

	while (ptr != 0) {
		OF_HASH_ADD(hash, ptr & 0xFF);
		ptr <<= 8;
	}

	OF_HASH_FINALIZE(hash);

	return hash;
}








|

|







803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
- (uint32_t)hash
{
	uintptr_t ptr = (uintptr_t)self;
	uint32_t hash;

	OF_HASH_INIT(hash);

	for (size_t i = 0; i < sizeof(ptr); i++) {
		OF_HASH_ADD(hash, ptr & 0xFF);
		ptr >>= 8;
	}

	OF_HASH_FINALIZE(hash);

	return hash;
}