Are you suggesting this as a debug feature ? Because if not then there are lots of ways process can be terminated without triggering the code, which will write such files on disk, so this one becomes useless.
Maybe. Of course I know that the app can be terminated which is impossible to detect, but if the app closes normally then it would write the virtual file to the disk. Sometimes it could be helpful in my opinion Maybe debugging, or further functions.