protected long ptrval(MemBuffer buf, int ptrSize) throws MemoryAccessException {
		switch (ptrSize) {
			case 2:
				return readWord(buf);
			case 4:
				return readDWord(buf);
			case 8:
				return readQWord(buf);
			default:
				throw new AddressTranslationException(
					"Don't know how to make a " + ptrSize + "-byte pointer");
		}
	}
Reads a <code>ptrSize</code> integer value at the address of <code>buf</code>
@param buf Buffer to read from
@param ptrSize the size of the pointer to be read.
@return The value of the pointer reference
@throws MemoryAccessException if the data can't be read
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/exceptionhandlers/gcc/AbstractDwarfEHDecoder.java