not yet correct implementation of path-exists-p, and some other supporting stuff