The w<>nil check is not necessary here. If it's nil, then w=self will also not be true.