[Ecls-list] interactive rename-file was open :supersede and rename-file advise

Geo Carncross geocar at gmail.com
Tue Nov 27 16:10:36 UTC 2007


Included is a new patch to rename-file. This one is interactive and
helps outline the semantics that I propose be added to open with
:RENAME-AND-DELETE

If a rename operation is attempted and the file exists, the new
rename-file reliably generates a condition with the following
restarts:

1. CONTINUE the rename, overwriting the original file
2. IGNORE the error (perhaps because the user did something else that
rename should now succeed)
3. ACCEPT the error causing RENAME-FILE to return NIL.

If this patch is accepted, I'd like to then modify OPEN to be
crashproof when given :IF-EXISTS :RENAME-AND-DELETE by using
cl_rename_file() to get these same capabilities.

This patch also patches up uses of CEerror() which didn't seem to
quite work right, and documents the change to RENAME-FILE.

I'm very curious if this breaks anyone's code, or if I should allocate
a special condition just for renaming files so that it's easier to
affect the restart dynamically and programatically.

As usual, the patch is also available via the web at:

http://geocar.googlepages.com/ecl-interactive-rename.patch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ecl-interactive-rename.patch
Type: text/x-patch
Size: 12229 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/ecl-devel/attachments/20071127/facac2e5/attachment.bin>


More information about the ecl-devel mailing list