summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Pitt <martinpitt@gnome.org>2013-01-15 10:05:20 +0100
committerMartin Pitt <martinpitt@gnome.org>2013-01-15 10:05:20 +0100
commitf65395f5f9f1ef980315ae11c454c324bb61e24d (patch)
tree08af0de69599d74b23896091b0c20b4b3b0d4a1f
parent5e4ddbcb8eacede04d5ade9e630d2efe29c022a0 (diff)
downloadgobject-introspection-f65395f5f9f1ef980315ae11c454c324bb61e24d.tar.gz
tests: Fix compiler warnings
Fix (void) function declarations that occur with -Wstrict-prototypes, and the g_param_spec_get_name() which drops the const from its argument.
-rw-r--r--tests/gimarshallingtests.c2
-rw-r--r--tests/gimarshallingtests.h2
-rw-r--r--tests/scanner/regress.c10
3 files changed, 7 insertions, 7 deletions
diff --git a/tests/gimarshallingtests.c b/tests/gimarshallingtests.c
index a81e4d86..21d31e00 100644
--- a/tests/gimarshallingtests.c
+++ b/tests/gimarshallingtests.c
@@ -4706,7 +4706,7 @@ gi_marshalling_tests_param_spec_in_bool (const GParamSpec *param)
{
g_assert (G_IS_PARAM_SPEC (param));
g_assert_cmpint (G_PARAM_SPEC_TYPE (param), ==, G_TYPE_BOOLEAN);
- g_assert_cmpstr (g_param_spec_get_name(param), ==, "mybool");
+ g_assert_cmpstr (g_param_spec_get_name((GParamSpec*) param), ==, "mybool");
}
/**
diff --git a/tests/gimarshallingtests.h b/tests/gimarshallingtests.h
index 10179c68..803b02c7 100644
--- a/tests/gimarshallingtests.h
+++ b/tests/gimarshallingtests.h
@@ -573,7 +573,7 @@ GClosure *gi_marshalling_tests_gclosure_return (void);
/**
* GIMarshallingTestsCallbackReturnValueOnly:
*/
-typedef glong (* GIMarshallingTestsCallbackReturnValueOnly) ();
+typedef glong (* GIMarshallingTestsCallbackReturnValueOnly) (void);
glong gi_marshalling_tests_callback_return_value_only (GIMarshallingTestsCallbackReturnValueOnly callback);
diff --git a/tests/scanner/regress.c b/tests/scanner/regress.c
index 89dc8738..b5fc8585 100644
--- a/tests/scanner/regress.c
+++ b/tests/scanner/regress.c
@@ -908,7 +908,7 @@ regress_test_array_int_null_out (int **arr, int *len)
/* GList */
static /*const*/ GList *
-regress_test_sequence_list()
+regress_test_sequence_list (void)
{
static GList *list = NULL;
if (!list) {
@@ -1029,7 +1029,7 @@ regress_test_glist_null_out (GSList **out_list)
/* GSList */
static /*const*/ GSList *
-regress_test_sequence_slist()
+regress_test_sequence_slist (void)
{
static GSList *list = NULL;
if (!list) {
@@ -1153,7 +1153,7 @@ static char *table_data[3][2] = {
};
static GHashTable *
-regress_test_table_ghash_new_container()
+regress_test_table_ghash_new_container (void)
{
GHashTable *hash;
int i;
@@ -1164,7 +1164,7 @@ regress_test_table_ghash_new_container()
}
static GHashTable *
-regress_test_table_ghash_new_full()
+regress_test_table_ghash_new_full (void)
{
GHashTable *hash;
int i;
@@ -1177,7 +1177,7 @@ regress_test_table_ghash_new_full()
}
static /*const*/ GHashTable *
-regress_test_table_ghash_const()
+regress_test_table_ghash_const (void)
{
static GHashTable *hash = NULL;
if (!hash) {