This works with a regular shell since the kernel can keep track of a deleted cwd. Since we just keep a path string, the following suppresses invocations fail.
I think this would also fail on windows.
lgtm