On Mon, 2009-09-21 at 03:33 +0100, Zhu, Yongsheng wrote: > > I gave this a try and think it should work - except that g++ 4.3 and 4.4 > > crash when the type case is enabled in methodFunction2. > > Without that line, the code compiles. Darn. If anyone has an idea how to > > make this work > > with existing compilers, feel free to help me out. > This should be a regression of GCC and a new bug in 4.2 and later version. > Someone said GCC 4.1.2 was ok. Please see below link: > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37093 > To be simpler, you can see comment#2, which shows a simple case to produce > this bug.
Yeah, that's the one. > This bug leaves unfixed for more than a year. I'm afraid that we may make a > decision to use > other workarounds for we don't know how long it could be fixed. Please work around it by adding glue code for the affected methods to Session. I'll think a bit about how this can be solved more elegantly without triggering the compiler bug. Extending the gdbus core so that it calls the C callbacks with two parameters (base pointer + per-callback data) might work, then we can use the per-callback pointer to find the method that we need to call instead of using a template parameter. It would also allow us to bind arbitrary functions, not just class members. -- Best Regards, Patrick Ohly The content of this message is my personal opinion only and although I am an employee of Intel, the statements I make here in no way represent Intel's position on the issue, nor am I authorized to speak on behalf of Intel on this matter. _______________________________________________ SyncEvolution mailing list [email protected] http://lists.syncevolution.org/listinfo/syncevolution
