[Libreoffice] [PATCH] Remove DECLARE_LIST(TOXControlList, Control*)

Michael Meeks michael.meeks at novell.com
Mon Dec 13 01:21:23 PST 2010


On Sun, 2010-12-12 at 20:26 -0800, Joseph Powers wrote:
> I played around in writer a little bit but couldn't figure out where
> this code was being used. If someone could point me in the right
> direction, I'll do a little more testing.

	Quite possibly it is simply not used :-) I guess, check the callcatcher
output. If you remove it, does writer still compile/link ? - the linker
may help tell you which symbols are used, and you can grep for those in
the object files (perhaps).

> The main issue is that my compiler (g++ 4.0) doesn't allow the
> following:

	I find this -very- hard to believe:

> class Foo;
> class Bar {
> Foo* myFoo;
> }

	That is perfectly valid C++, and always has been AFAIK. I suspect there
is a bug in your code / thinking somehow.

	Now if you want:

class Bar {
	Foo myFoo;
};

	that isn't going to fly without defining Foo first, but a pointer type,
(or a reference) - has to work properly, or the world fails in a storm
of indeterminism ;-)

	I strongly suspect the problem is elsewhere; perhaps in some in-line
method / template using methods of Foo or something (?) - but just
defining that should be fine.

> Because of this, I need to move enough information from the .cxx
> into .hxx to define Foo before Bar; however, Foo is build using some
> more magic Macros so I don't know how much code I can safely move to
> the header. Any suggestions on this would be nice.

	It'd be great to have a dump of the real file in question & the errors,
to have a closer look.

> The only two DECLARE_LIST() instances left in writer are the above

	Nice work :-)

	All the best,

		Michael.

-- 
 michael.meeks at novell.com  <><, Pseudo Engineer, itinerant idiot




More information about the LibreOffice mailing list