[Ecls-list] Merge DELETE-FILE and RMDIR?

Waldek Hebisch hebisch at math.uni.wroc.pl
Wed Oct 12 18:49:51 UTC 2011

Juan Jose Garcia-Ripoll wrote:
> I have found it quite annoying lately having to think whether I want to use
> EXT:RMDIR or DELETE-FILE on a path. Would you find it ok if I merge both?
> The only implementation that seems to support this is ABCL.

For me (and FriCAS) this change is ok, but does not help.  In my
case directories to be removed are nonempty, so I actually need
recursive removal.  And to be portable I need to test for directories

One thing to consider is consistency between PROBE-FILE, RENAME-FILE
and DELETE-FILE.  While legal, it would be embarassing if PROBE-FILE
said that file does not exist but DELETE-FILE succesfully removed
directory.  Similarly, if directories are supposed to be files
in DELETE-FILE IMHO they should also be allowed in RENAME-FILE.

Personally I like POSIX approach where directoris can be treated
as files when it makes sense.  It seems that some Lisp implementations
consider files and directories as leaving in essentially different
words and do not allow mixing operations on files and directories.
I think that it is more important to be consitent -- make one
choice and consequently use it in all filesystem functions.

                              Waldek Hebisch
hebisch at math.uni.wroc.pl 

More information about the ecl-devel mailing list