[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SETF and pathname slots
- To: ghenis.pasa@Xerox.COM
- Subject: SETF and pathname slots
- From: Robert W. Kerns <RWK@YUKON.SCRC.Symbolics.COM>
- Date: Fri, 17 Apr 87 12:58 EDT
- Cc: email@example.com
- In-reply-to: <870416-170308-1688@Xerox>
Date: 16 Apr 87 17:01 PDT
Should the standard require SETF to handle pathname slots? If we are
going to have MAKE-PATHNAME, PATHNAME-DEVICE, etc, for consistency we
should also have COPY-PATHNAME and be able to do things like (SETF
(PATHNAME-TYPE old-path) "OLD"). Is there any reason not to?
Careful. Not all systems have pathnames which can be modified.
In our case, it's because we want to preserve EQness of pathnames
with the same components. In other (hypothetical) cases, a pathname
may be an operating-system-related object that you aren't allowed
to directly modify; you request a new one.
The answer is to treat (SETF (PATHNAME-NAME PATH) NEW-NAME)
like (SETF PATH (MAKE-PATHNAME :NAME NEW-NAME :DEFAULTS PATH)).
This is analogous with SETF of LDB.