Replace redundant writePointer implementation