[glib/wip/hadess/update-installed-tests-ci: 4/7] Revert "Add G_TYPE_UUID"
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/wip/hadess/update-installed-tests-ci: 4/7] Revert "Add G_TYPE_UUID"
- Date: Wed, 11 Dec 2019 13:14:50 +0000 (UTC)
commit 3282ee6bc7999f91a5a02bb843817e736d6c256a
Author: Bastien Nocera <hadess hadess net>
Date: Tue Jan 9 16:06:22 2018 +0100
Revert "Add G_TYPE_UUID"
This reverts commit 4f30c0ed82f5995bd0248774a7079d8cf08dad7e.
docs/reference/gobject/gobject-sections.txt | 1 -
gobject/gboxed.c | 9 ---------
gobject/glib-types.h | 11 -----------
gobject/tests/boxed.c | 27 ---------------------------
4 files changed, 48 deletions(-)
---
diff --git a/docs/reference/gobject/gobject-sections.txt b/docs/reference/gobject/gobject-sections.txt
index 90cb39773..bed38e4c5 100644
--- a/docs/reference/gobject/gobject-sections.txt
+++ b/docs/reference/gobject/gobject-sections.txt
@@ -408,7 +408,6 @@ G_TYPE_SOURCE
G_TYPE_POLLFD
G_TYPE_THREAD
G_TYPE_OPTION_GROUP
-G_TYPE_UUID
<SUBSECTION Standard>
G_TYPE_IS_BOXED
diff --git a/gobject/gboxed.c b/gobject/gboxed.c
index 005de6058..87cc5d2c2 100644
--- a/gobject/gboxed.c
+++ b/gobject/gboxed.c
@@ -95,14 +95,6 @@ pollfd_copy (GPollFD *src)
return dest;
}
-static GUuid *
-uuid_copy (GUuid *src)
-{
- GUuid *dest = g_new (GUuid, 1);
- memcpy (dest, src, sizeof (GUuid));
- return dest;
-}
-
void
_g_boxed_type_init (void)
{
@@ -177,7 +169,6 @@ G_DEFINE_BOXED_TYPE (GMarkupParseContext, g_markup_parse_context, g_markup_parse
G_DEFINE_BOXED_TYPE (GThread, g_thread, g_thread_ref, g_thread_unref)
G_DEFINE_BOXED_TYPE (GChecksum, g_checksum, g_checksum_copy, g_checksum_free)
-G_DEFINE_BOXED_TYPE (GUuid, g_uuid, uuid_copy, g_free)
G_DEFINE_BOXED_TYPE (GOptionGroup, g_option_group, g_option_group_ref, g_option_group_unref)
diff --git a/gobject/glib-types.h b/gobject/glib-types.h
index 7190f2e4a..78a199d1d 100644
--- a/gobject/glib-types.h
+++ b/gobject/glib-types.h
@@ -297,15 +297,6 @@ typedef gsize GType;
*/
#define G_TYPE_OPTION_GROUP (g_option_group_get_type ())
-/**
- * G_TYPE_UUID:
- *
- * The #GType for a boxed type holding a #GUuid.
- *
- * Since: 2.48
- */
-#define G_TYPE_UUID (g_uuid_get_type ())
-
GLIB_AVAILABLE_IN_ALL
GType g_date_get_type (void) G_GNUC_CONST;
GLIB_AVAILABLE_IN_ALL
@@ -362,8 +353,6 @@ GLIB_AVAILABLE_IN_2_40
GType g_mapped_file_get_type (void) G_GNUC_CONST;
GLIB_AVAILABLE_IN_2_44
GType g_option_group_get_type (void) G_GNUC_CONST;
-GLIB_AVAILABLE_IN_2_48
-GType g_uuid_get_type (void) G_GNUC_CONST;
GLIB_DEPRECATED_FOR('G_TYPE_VARIANT')
GType g_variant_get_gtype (void) G_GNUC_CONST;
diff --git a/gobject/tests/boxed.c b/gobject/tests/boxed.c
index eff50346c..70e3ea762 100644
--- a/gobject/tests/boxed.c
+++ b/gobject/tests/boxed.c
@@ -366,32 +366,6 @@ test_boxed_datetime (void)
g_value_unset (&value);
}
-static void
-test_boxed_uuid (void)
-{
- GUuid v;
- GUuid *v1;
- GUuid *v2;
- GValue value = G_VALUE_INIT;
-
- g_value_init (&value, G_TYPE_UUID);
- g_assert (G_VALUE_HOLDS_BOXED (&value));
-
- g_uuid_generate_v4 (&v);
- g_value_set_boxed (&value, &v);
-
- v1 = g_value_dup_boxed (&value);
- g_assert (v1 != &v); /* uuids are copied values */
- g_assert (g_uuid_equal (v1, &v));
- g_value_reset (&value);
-
- g_value_take_boxed (&value, v1);
- v2 = g_value_get_boxed (&value);
- g_assert (v2 == v1);
-
- g_value_unset (&value);
-}
-
static void
test_boxed_error (void)
{
@@ -670,7 +644,6 @@ main (int argc, char *argv[])
g_test_add_func ("/boxed/markup", test_boxed_markup);
g_test_add_func ("/boxed/thread", test_boxed_thread);
g_test_add_func ("/boxed/checksum", test_boxed_checksum);
- g_test_add_func ("/boxed/uuid", test_boxed_uuid);
return g_test_run ();
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]