From a3a9664ed202303b899ca55625877542309d1a1f Mon Sep 17 00:00:00 2001 From: Marc-Antoine Perennou Date: Sat, 9 Nov 2013 12:09:20 +0900 Subject: [PATCH] make *_get_instance_private const-compliant This is pure read-only access to an external struct so void warnings for people calling it from const contexts such as accessors https://bugzilla.gnome.org/show_bug.cgi?id=745068 Signed-off-by: Marc-Antoine Perennou --- gobject/gtype.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gobject/gtype.h b/gobject/gtype.h index fadaadb95..68bc051f1 100644 --- a/gobject/gtype.h +++ b/gobject/gtype.h @@ -1938,7 +1938,7 @@ _G_DEFINE_TYPE_EXTENDED_CLASS_INIT(TypeName, type_name) \ \ G_GNUC_UNUSED \ static inline gpointer \ -type_name##_get_instance_private (TypeName *self) \ +type_name##_get_instance_private (const TypeName *self) \ { \ return (G_STRUCT_MEMBER_P (self, TypeName##_private_offset)); \ } \