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: Unwanted hook names (was Re: interface reductions)


"Greg J. Badros" <gjb@cs.washington.edu> writes:

> But the point is to be able to leverage structure in the names to avoid
> having to do that, and to enable arbitrary such sets to be decided.
> Having a guaranteed canonical name for a system-special object seems
> like a good thing to me.

You should use the module system for that, and not kludge a name onto
every value.

If you really want to, you can implement a special purpose name-space
for hooks, by putting them into a hash-table or something.  How are
you going to make use of hook names anyway?  I guess you have a list
of hooks, and then you run down the list and retrieve the name of a
hook.  How is that different from having a list of name/hook mappings
and you run down the this list instead, retrieving the name from the
mapping and maybe the hook object if you are interested in it.

With such an arrangement, you can also have more than one name for a
single hook, for example.

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