GNOME Bugzilla – Bug 526102
The G_TYPE_CHECK_INSTANCE_CAST() macro does not emit a warning if an instance structure is not of the expected type
Last modified: 2008-06-10 12:02:02 UTC
According to the specification of the macro G_TYPE_CHECK_INSTANCE_CAST() "Checks that instance is an instance of the type identified by g_type and emits a warning if this is not the case." Whenever instance structure type does not match the type id, passed in for a second parameter, the warning is not get emitted. The detailed bug description can be found at: http://linuxtesting.org/results/report?num=D0074
Created attachment 108589 [details] The test case reproducing the bug
G_TYPE_CHECK_INSTANCE_CAST() does generate a warning. G_TYPE_CHECK_INSTANCE_TYPE() does not warn. your test uses G_TYPE_CHECK_INSTANCE_TYPE() instead of G_TYPE_CHECK_INSTANCE_CAST(), so needs to be fixed.