diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2013-08-21 12:16:10 +0100 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2013-08-21 12:16:48 +0100 |
commit | 5b6ada6b362f3ff160608c00bcffbb8f2b8eff7b (patch) | |
tree | 63100cde96b821d43a07bdcc90c11050fe00fc44 /json-glib/json-generator.c | |
parent | 361e427316cc50b52e4b8f0a71a2b29d1a02ed36 (diff) | |
download | json-glib-5b6ada6b362f3ff160608c00bcffbb8f2b8eff7b.tar.gz |
Remove compile time GLib version check
We depend on a new version of GLib, so we can remove a bunch of old
version checks.
Diffstat (limited to 'json-glib/json-generator.c')
-rw-r--r-- | json-glib/json-generator.c | 14 |
1 files changed, 1 insertions, 13 deletions
diff --git a/json-glib/json-generator.c b/json-glib/json-generator.c index 04beaf4..8621b02 100644 --- a/json-glib/json-generator.c +++ b/json-glib/json-generator.c @@ -41,11 +41,7 @@ #include "json-marshal.h" #include "json-generator.h" -#if GLIB_CHECK_VERSION (2, 37, 3) -# define JSON_GENERATOR_GET_PRIVATE(obj) ((JsonGeneratorPrivate *) json_generator_get_instance_private ((JsonGenerator *) (obj))) -#else -# define JSON_GENERATOR_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), JSON_TYPE_GENERATOR, JsonGeneratorPrivate)) -#endif +#define JSON_GENERATOR_GET_PRIVATE(obj) ((JsonGeneratorPrivate *) json_generator_get_instance_private ((JsonGenerator *) (obj))) struct _JsonGeneratorPrivate { @@ -112,11 +108,7 @@ static const char json_exceptions[] = { static GParamSpec *generator_props[PROP_LAST] = { NULL, }; -#if GLIB_CHECK_VERSION (2, 37, 3) G_DEFINE_TYPE_WITH_PRIVATE (JsonGenerator, json_generator, G_TYPE_OBJECT) -#else -G_DEFINE_TYPE (JsonGenerator, json_generator, G_TYPE_OBJECT) -#endif static gchar * json_strescape (const gchar *str) @@ -200,10 +192,6 @@ json_generator_class_init (JsonGeneratorClass *klass) { GObjectClass *gobject_class = G_OBJECT_CLASS (klass); -#if !GLIB_CHECK_VERSION (2, 37, 3) - g_type_class_add_private (klass, sizeof (JsonGeneratorPrivate)); -#endif - /** * JsonGenerator:pretty: * |