[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Object Lisp Question

Hi.  Today I started using the object system in MACL 1.3.1 and I ran into a
compiler warning that I don't understand.  When I eval:

     (defobfun (ed-set-small *fred-window*) ()
       (if (not (ask (self) (ownp 'small-size)))
         (progn (ask (self) (have 'small-size))
                (ask (self) (have 'small-pos))))
       (ask (self) (setq small-size (ask (self) (window-size))))
       (ask (self) (setq small-pos (ask (self) (window-position)))))

I get:

     Compiler warnings for function ED-SET-SMALL :
       Undeclared free variables (SMALL-SIZE SMALL-POS)

The code works fine (i.e. it creates a small-size variable in the
particular fred window), but I'm curious about why this warning is
generated.  I know that replacing the (setq small-size ...) with
(setf (symbol-value 'small-size) ...) makes the warning disappear, but this
seems verbose.