pointers-changed function