[DGD] Melville under the Kernel Lib
Felix A. Croes
felix at dworkin.nl
Fri Feb 6 19:06:30 CET 2004
Stephen Schmidt <schmidsj at union.edu> wrote:
> On Fri, 6 Feb 2004, Felix A. Croes wrote:
>[...]
> > Here is what the kernel library does, and what a modern mudlib should do:
> > [snip]
> > - A framework for persistence.
>
> I'm not sure I agree. Surely a mudlib can be useful and "modern"
> even without supporting persistence? Not all applications require
> persistence. (I do concur with Noah that if you use a mudlib that
> does not support persistence, you are sacrificing a big feature
> of DGD. But DGD has other features besides persistence which can
> sell it to someone who doesn't need/want persistence.)
I was thinking of a mudlib that does not only have most of the kernel
library's functionality, but also plays the same role: it is in
public distribution and used by people whose ideas about muds are
not necessarily those of the author. So a new mudlib should support
persistence (which is easy anyway), just like the kernel library can
be used as the basis for a non-persistent mud (which is not how I
think it should be used).
> > - There have to be some kind of thread-local variables which are not
> > held in any object, to handle things such as this_player().
>
> How does one have a variable which is not held in some object?
> Even if it be the driver object?
In the kernel library these are variables in "Thread Local Storage".
It makes use of the fact that call_trace() returns an array of
function calls, including the arguments for those calls. The elements
of an array among those arguments can be modified, and can thus be
used to hold values that only last for as long as the current thread,
while not being local to any object. The kernel library ensures that
the first call in the call trace always includes such an array, and it
exports an interface to query and set these values, using
/kernel/lib/api/tls.
Regards,
Dworkin
_________________________________________________________________
List config page: http://list.imaginary.com/mailman/listinfo/dgd
More information about the DGD
mailing list