Subject: Re: setf functions
From: Erik Naggum <>
Date: 2000/04/05
Newsgroups: comp.lang.lisp
Message-ID: <>

* Harald Hanche-Olsen <>
| My point is that, as far as I can understand the Hyperspec, there is
| no way to do this for a function returning multiple values, since the
| form should be a place, which by definition can only refer to a single
| value.  I'd love to be proved wrong on this one, though.  Or even if I
| am right, maybe there is a more natural way to attack the problem?

  apart from actually working, what's wrong with this example?

(defstruct display
  x y)

(defun global-pointer-position (object)
  (values (display-x object) (display-y object)))

(defsetf global-pointer-position (object) (new-x new-y)
  `(setf (display-x ,object) ,new-x
	 (display-y ,object) ,new-y))