From 60f34a1f51d455598143c1c55fd49a5eb1bb1fd6 Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Tue, 21 May 2019 10:14:23 -0500 Subject: [PATCH] gnome: use g_intern_static_string() for enum/flags type names We are emitting a static string, so use that shortcut function to intern it, which will save one allocation. --- mesonbuild/modules/gnome.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py index 9cb0323f0..e20bae6b1 100644 --- a/mesonbuild/modules/gnome.py +++ b/mesonbuild/modules/gnome.py @@ -1415,7 +1415,7 @@ GType c_file_kwargs['vtail'] = ''' { 0, NULL, NULL } }; if (g_once_init_enter (>ype_id)) { - GType new_type = g_@type@_register_static ("@EnumName@", values); + GType new_type = g_@type@_register_static (g_intern_static_string ("@EnumName@"), values); g_once_init_leave (>ype_id, new_type); } return (GType) gtype_id;