Sysop: | Amessyroom |
---|---|
Location: | Fayetteville, NC |
Users: | 26 |
Nodes: | 6 (1 / 5) |
Uptime: | 07:52:25 |
Calls: | 483 |
Calls today: | 1 |
Files: | 1,073 |
Messages: | 98,053 |
(defun sans (plist &rest keys)
"Returns PLIST with keyword arguments from KEYS removed."
;; stolen from Usenet posting <3247672165664225@naggum.no> by
;; Erik Naggum
(let ((sans ()))
(loop
(let ((tail (nth-value 2 (get-properties plist keys))))
;; this is how it ends
(unless tail
(return (nreconc sans plist)))
;; copy all the unmatched keys
(loop until (eq plist tail) do
(push (pop plist) sans)
(push (pop plist) sans))
;; skip the matched key
(setq plist (cddr plist))))))