Re: gtkmm2.4 and MSVC (again)

Murray Cumming wrote:
This is strangely similar to a dynamic_cast<> problem that existed in g++

So it might be a compiler bug with use of dynamic_cast<> in the
constructor of with classes that use multiple inheritance. But to reach
that conclusion we would need a non-gtkmm test case.

This begins to look like the problem - enclosed is a simplification of Matt's test case that should be clearer to look at, I am currently fiddling-around to try and create a C++-only test case.

In the meantime, please make sure that any extra project file changes are
in our CVS, so that we are starting at the same point. I have access to
MSVC++ .Net 2003, so I might take a look if your own efforts don't reach a

Unless I've got the wrong branch, the MSVC files aren't in gtkmm CVS yet, are they?

#include <gtkmm/main.h>
#include <gtkmm/window.h>
#include <iostream>

// As written, this program will generate a "no RTTI data!" at runtime when
// compiled with Visual Studio .NET 2003
// There are two ways to eliminate the exception, either:
// * Comment-out the member variable derived::x, or
// * Comment-out the call to show() in base::base(), and un-comment the call to show in derived::derived()

class base :
	public Gtk::Window
	base() :
		catch(bad_typeid x)
				std::cout << "Exception " << x.what() << std::endl;

class derived :
	public base
	derived() :
		// show();

	int x;

int main(int argc, char **argv)
	Gtk::Main m(&argc, &argv);

	derived w;;

	return 0;

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]