From dgd@dworkin.nl Thu Jun 23 01:54:01 2005 From: dgd@dworkin.nl (Felix A. Croes) Date: Thu Jun 23 00:54:01 2005 Subject: [DGD] Why export data structures? [oops -- original response not sent to the list] > This is really just a question out of curiousity. I was thinking of coding > something that relied on several objects having access to the same data > structure - in this case a mapping. But then I learned that such data > structures are made into individual copies in all objects referencing it > at the end of the execution thread. So as I understand it, the objects > would no longer be referencing the same data in later threads. > > Now, I have no reason to be upset why it works like this. I am merely > being curious as to the reasons. Why does DGD do this? If someone's got > the time to satiate my curiousity, I'd be happy! That way, all data remains local to a (persistent) object. The only crossreferences between objects are those that pass through an object reference, which is handled in a special way. As a result, memory management and swapfile allocation become much simpler and scale better. This is even more important for DGD/MP. Regards, Dworkin