Fix expunging of empty memory series (loop var pointerization bug)

This fixes the hanging tests and nil pointer dereference exception in `memory.go`.