[Gtk-sharp-list] Strange compiler errors and runtime crashes on Windows
chris at lee-gertner.net
Wed Apr 18 00:02:08 EDT 2007
I'm having new problems in my port of Gtk# code from Linux to Windows.
The first scary thing is that I was getting compiler errors (in Windows)
Plot.cs(116,36): error CS0029: Cannot implicitly convert type
`StripChart.Plot.plotSurface' to `Gtk.Widget'
where plotSurface is a Gtk.Widget (compiled in a separate .dll before).
I was also getting a strange error in some boilerplate ButtonEvent code:
gave me the error:
Plot.cs(126,17): error CS0019: Operator `+' cannot be applied to operands of
type `Gtk.ButtonPressEventHandler' and `Gtk.ButtonPressEventHandler'
The same code compiles fine under mono-188.8.131.52 in Edgy-Eft Ubuntu linux
(on Windows, I'm using the latest Mono/Gtk-sharp 184.108.40.206 windows
distribution from Novell).
I'm wondering if this was somehow caused by adding and removing the
different Gtk# runtimes and SDKs. I've made sure I have only the basic
mono-installer version now, but I'm still getting this error.
Also, when I comment-out the code causing the compile errors I'm getting
many run-time crashes in the unmanaged Gtk code. I can clear some of
them by trial and error, by doing things like changing a class from
subclassing a Gtk.VBox to containing a Gtk.VBox as a member.
I'm wondering if I am seeing differences having to do with how quickly
my temporary objects are getting garbage-collected or something -- I'm
running the windows stuff in a virtual machine with limited memory
(WinXP, running under Parallels, under Linux).
Or maybe the runtime crashes have something to do with the compiler
More information about the Gtk-sharp-list