This is the mail archive of the guile@sourceware.cygnus.com mailing list for the Guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Trouble understanding define (!)


Michael Livshin writes:

   why would you ever want to block your methods from extending an
   imported generic?  so you can have something like CL's `with-methods'
   in a module scope?  while this does seem possible, it hardly seems
   useful.

Just to avoid spurious name conflicts.  Suppose you import a module
that includes a generic function called "smith", but "smith" is not
the reason why you are importing the module.  Then suppose that
"smith" also happens to be the most appropriate name for a generic
function that you want in your own application code.

   one addition: defining a class slot with an
   (#:accessor/#:setter/#:getter NAME) argument raises error if
   (not (is-a? GF NAME)).

Good idea.

Regards,

        Neil

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]