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

Re: Redefinition of print-object



Bruno wrote:
> 
> >    WARNING:
> >    The generic function #<GENERIC-FUNCTION PRINT-OBJECT> is being modified, but has already been called.
> 
> > I would like to know if this might be a problem with my installation.
> 
> Not at all. The function PRINT-OBJECT is called when lispinit.mem is
> built (on objects of type CONDITION), and the info that it has been called
> is remembered in lispinit.mem.
> 
> I am a bit unhappy about this warning because PRINT-OBJECT is meant to
> be extended even after having been called, but I don't see in which
> respect PRINT-OBJECT is special among all generic functions.

It seems to be my turn for the weekly enhancement wish... :-) :-)

The background: It concerns CLOS language extensions or installation
of applications. In both cases the user works with a virtual platform
that should be `clean' for him. I get mails from users that want to
install an application and ask now if something went wrong. (Yes,
they're no Lisp programmers -- real (l)users...)
    Of course, the quick fix is to add this to the documentation. But
then, who reads documentation? And so I would like to get rid of this
superfluous warning.

How about:

 (a) An additional argument to #'saveinitmem that tells CLISP that all
     definitions are clean (i.e., not used).
	That can be used if this memory image shall be a virtual
     machine where the user shall not see its internal structure. The
     default of this argument is nil.

or

 (b) some global variable (in package system?) that controls the
     output of such warnings. (And that I can turn off in my
     installation scripts.)

or

 (c) Some way to tell #'load that it shall not issue such a warning.
     Perhaps via the value of verbose? Or an additional keyword parameter?

I must say, I like (a) since it matches exactly my usage of Lisp. (c)
is IMO problematic since it's outside dpANS (is it?).

Comments, anybody?

	Joachim

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Joachim Schrod			Email: schrod@iti.informatik.th-darmstadt.de
Computer Science Department
Technical University of Darmstadt, Germany