RE: cbdata

From: Alex Rousskov <>
Date: Thu, 12 Jul 2001 10:26:34 -0600 (MDT)

On Thu, 12 Jul 2001, Chemolli Francesco (USI) wrote:

> I suggest we mutuate an habit from lisp, which is to use a suffix
> to determine whether a function is a test-function or not. In our
> case, I'd rename cbdataValid to cbdataValidp (p is for predicate).

I would vote against that. A compiler would catch an error if someone
is using a return value of a function that returns void. Why make
names longer and harder to read?
> Can we attach hooks to events on the object (i.e. a callback to be
> invoked when the object gets distructed?). Also, it could be nice
> extending the callback system so that multiple callbacks can be
> assigned to a single hook. It would probably decrease performance,
> but it could be a good help in improving modularization.

I think this goes way beyond cbdata purpose. In my experience, such
hooks are making things simpler *on the surface* but lead to awful
dependencies and hard-to-find bugs. Humans have trouble thinking
non-linearly or in-parallel and hooks that get called on some event
require such thinking. I would prefer to avoid them as much as
possible. It is just my opinion though.

Received on Thu Jul 12 2001 - 10:26:59 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:14:07 MST