[PATCH] shared dpointer for duchain

David Nolden zwabel at googlemail.com
Mon Dec 17 23:18:26 UTC 2007


On Monday 17 December 2007 23:17:36 Andreas Pakulat wrote:
> As you can see I finally found all difference in initialisation order
> and behaviour and now duchain works and uses a shared dpointer. I'm
> going for the typesystem next.

Great.

> Howevre I'd like to know: Is there any chance to make duchain a bit less
> fragile? I know this might be undo-able and is probably at least hard
> due to the multi-threading issues, but I guess somebody starting with
> this and getting the order of things wrong would appreciate it if it
> wouldn't simply break down in 1000 small pieces on him :) Without a good
> hint as to why it falls apart.

The problem is that a structure that is designed to be read-only is changed by 
inserting new items(using the clone() thing), that's probably the main thing 
that makes it fragile, There's an exact path that must be followed so it 
doesn't break and everything stays valid in all moments. The good thing is 
that maybe we will only need this for C++, so there won't be many who will 
stumble on that problem.

greetings, David




More information about the KDevelop-devel mailing list