# HG changeset patch
# Node ID 8a3b83f9eef2
# Parent  3880a5d25cf2
diff --git a/gplugin-gtk3/gplugin-gtk-plugin-info.c b/gplugin-gtk3/gplugin-gtk-plugin-info.c
--- a/gplugin-gtk3/gplugin-gtk-plugin-info.c
+++ b/gplugin-gtk3/gplugin-gtk-plugin-info.c
@@ -79,7 +79,7 @@
 	NULL,
 };
 
-G_DEFINE_TYPE(GPluginGtkPluginInfo, gplugin_gtk_plugin_info, GTK_TYPE_BOX);
+G_DEFINE_TYPE(GPluginGtkPluginInfo, gplugin_gtk_plugin_info, GTK_TYPE_BOX)
 
 /******************************************************************************
  * Callbacks
@@ -261,7 +261,10 @@
  * Callbacks
  *****************************************************************************/
 static void
-gplugin_gtk_plugin_info_state_cb(GObject *obj, GParamSpec *pspec, gpointer data)
+gplugin_gtk_plugin_info_state_cb(
+	G_GNUC_UNUSED GObject *obj,
+	G_GNUC_UNUSED GParamSpec *pspec,
+	gpointer data)
 {
 	_gplugin_gtk_plugin_info_refresh(GPLUGIN_GTK_PLUGIN_INFO(data));
 }
diff --git a/gplugin-gtk3/gplugin-gtk-store.c b/gplugin-gtk3/gplugin-gtk-store.c
--- a/gplugin-gtk3/gplugin-gtk-store.c
+++ b/gplugin-gtk3/gplugin-gtk-store.c
@@ -55,7 +55,7 @@
 	GtkListStore parent;
 };
 
-G_DEFINE_TYPE(GPluginGtkStore, gplugin_gtk_store, GTK_TYPE_LIST_STORE);
+G_DEFINE_TYPE(GPluginGtkStore, gplugin_gtk_store, GTK_TYPE_LIST_STORE)
 
 /******************************************************************************
  * Globals
@@ -143,7 +143,7 @@
 static gboolean
 gplugin_gtk_store_update_plugin_state_cb(
 	GtkTreeModel *model,
-	GtkTreePath *path,
+	G_GNUC_UNUSED GtkTreePath *path,
 	GtkTreeIter *iter,
 	gpointer data)
 {
@@ -202,7 +202,7 @@
  *****************************************************************************/
 static void
 gplugin_gtk_store_plugin_loaded_cb(
-	GObject *manager,
+	G_GNUC_UNUSED GObject *manager,
 	GPluginPlugin *plugin,
 	gpointer data)
 {
@@ -211,7 +211,7 @@
 
 static void
 gplugin_gtk_store_plugin_unloaded_cb(
-	GObject *manager,
+	G_GNUC_UNUSED GObject *manager,
 	GPluginPlugin *plugin,
 	gpointer data)
 {
diff --git a/gplugin-gtk3/gplugin-gtk-view.c b/gplugin-gtk3/gplugin-gtk-view.c
--- a/gplugin-gtk3/gplugin-gtk-view.c
+++ b/gplugin-gtk3/gplugin-gtk-view.c
@@ -67,7 +67,7 @@
  *****************************************************************************/
 static void
 gplugin_gtk_view_plugin_toggled_cb(
-	GtkCellRendererToggle *rend,
+	G_GNUC_UNUSED GtkCellRendererToggle *rend,
 	gchar *path,
 	gpointer data)
 {
@@ -127,7 +127,7 @@
 /******************************************************************************
  * GObject Implementation
  *****************************************************************************/
-G_DEFINE_TYPE(GPluginGtkView, gplugin_gtk_view, GTK_TYPE_TREE_VIEW);
+G_DEFINE_TYPE(GPluginGtkView, gplugin_gtk_view, GTK_TYPE_TREE_VIEW)
 
 static void
 gplugin_gtk_view_set_property(
diff --git a/gplugin/gplugin-loader.c b/gplugin/gplugin-loader.c
--- a/gplugin/gplugin-loader.c
+++ b/gplugin/gplugin-loader.c
@@ -69,7 +69,7 @@
 G_DEFINE_ABSTRACT_TYPE_WITH_PRIVATE(
 	GPluginLoader,
 	gplugin_loader,
-	G_TYPE_OBJECT);
+	G_TYPE_OBJECT)
 
 /******************************************************************************
  * Helpers
diff --git a/gplugin/gplugin-manager.h b/gplugin/gplugin-manager.h
--- a/gplugin/gplugin-manager.h
+++ b/gplugin/gplugin-manager.h
@@ -35,7 +35,7 @@
 	gplugin_manager,
 	GPLUGIN,
 	MANAGER,
-	GObject);
+	GObject)
 
 typedef void (*GPluginManagerForeachFunc)(
 	const gchar *id,
diff --git a/gplugin/gplugin-manager.c b/gplugin/gplugin-manager.c
--- a/gplugin/gplugin-manager.c
+++ b/gplugin/gplugin-manager.c
@@ -86,7 +86,7 @@
 	gboolean refresh_needed;
 } GPluginManagerPrivate;
 
-G_DEFINE_TYPE_WITH_PRIVATE(GPluginManager, gplugin_manager, G_TYPE_OBJECT);
+G_DEFINE_TYPE_WITH_PRIVATE(GPluginManager, gplugin_manager, G_TYPE_OBJECT)
 
 /******************************************************************************
  * Globals
@@ -191,7 +191,7 @@
 gplugin_manager_load_dependencies(
 	GPluginManager *manager,
 	GPluginPlugin *plugin,
-	GPluginPluginInfo *info,
+	G_GNUC_UNUSED GPluginPluginInfo *info,
 	GError **error)
 {
 	GSList *dependencies = NULL, *l = NULL;
diff --git a/gplugin/gplugin-native-loader.c b/gplugin/gplugin-native-loader.c
--- a/gplugin/gplugin-native-loader.c
+++ b/gplugin/gplugin-native-loader.c
@@ -58,7 +58,7 @@
 	GPluginLoader parent;
 };
 
-G_DEFINE_TYPE(GPluginNativeLoader, gplugin_native_loader, GPLUGIN_TYPE_LOADER);
+G_DEFINE_TYPE(GPluginNativeLoader, gplugin_native_loader, GPLUGIN_TYPE_LOADER)
 
 /******************************************************************************
  * Helpers
diff --git a/gplugin/gplugin-native-plugin.c b/gplugin/gplugin-native-plugin.c
--- a/gplugin/gplugin-native-plugin.c
+++ b/gplugin/gplugin-native-plugin.c
@@ -199,7 +199,7 @@
 	G_TYPE_TYPE_MODULE,
 	G_IMPLEMENT_INTERFACE(
 		GPLUGIN_TYPE_PLUGIN,
-		gplugin_native_plugin_iface_init));
+		gplugin_native_plugin_iface_init))
 
 static void
 gplugin_native_plugin_get_property(
diff --git a/gplugin/gplugin-plugin.c b/gplugin/gplugin-plugin.c
--- a/gplugin/gplugin-plugin.c
+++ b/gplugin/gplugin-plugin.c
@@ -77,7 +77,7 @@
 	0,
 };
 
-G_DEFINE_INTERFACE(GPluginPlugin, gplugin_plugin, G_TYPE_INVALID);
+G_DEFINE_INTERFACE(GPluginPlugin, gplugin_plugin, G_TYPE_INVALID)
 
 /******************************************************************************
  * Object Stuff
diff --git a/gplugin/gplugin-version.c b/gplugin/gplugin-version.c
--- a/gplugin/gplugin-version.c
+++ b/gplugin/gplugin-version.c
@@ -223,8 +223,8 @@
 		return "gplugin version too old (major mismatch)";
 	}
 
-	/* disable the pvs-studio suppression after 1.0.0 is released */
-	if(major < GPLUGIN_MAJOR_VERSION) { //-V547
+	/* This will warn until 1.0.0 is released. */
+	if(major < GPLUGIN_MAJOR_VERSION) {
 		return "gplugin version too new (major mismatch)";
 	}
 
diff --git a/gplugin/tests/dynamic-type/dynamic-type-provider.c b/gplugin/tests/dynamic-type/dynamic-type-provider.c
--- a/gplugin/tests/dynamic-type/dynamic-type-provider.c
+++ b/gplugin/tests/dynamic-type/dynamic-type-provider.c
@@ -21,7 +21,7 @@
 
 #include "dynamic-test.h"
 
-G_DEFINE_DYNAMIC_TYPE(DynamicTest, dynamic_test, G_TYPE_OBJECT);
+G_DEFINE_DYNAMIC_TYPE(DynamicTest, dynamic_test, G_TYPE_OBJECT)
 
 static void
 dynamic_test_init(G_GNUC_UNUSED DynamicTest *inst)
diff --git a/gplugin/tests/test-find-plugins.c b/gplugin/tests/test-find-plugins.c
--- a/gplugin/tests/test-find-plugins.c
+++ b/gplugin/tests/test-find-plugins.c
@@ -26,7 +26,7 @@
 test_gplugin_manager_foreach_load_plugins(
 	G_GNUC_UNUSED const gchar *id,
 	GSList *plugins,
-	gpointer data)
+	G_GNUC_UNUSED gpointer data)
 {
 	GPluginManager *manager = gplugin_manager_get_default();
 	GSList *l = NULL;
@@ -40,7 +40,7 @@
 test_gplugin_manager_foreach_unload_plugins(
 	G_GNUC_UNUSED const gchar *id,
 	GSList *plugins,
-	gpointer data)
+	G_GNUC_UNUSED gpointer data)
 {
 	GPluginManager *manager = gplugin_manager_get_default();
 	GSList *l = NULL;
diff --git a/gplugin/tests/test-loader-registration.c b/gplugin/tests/test-loader-registration.c
--- a/gplugin/tests/test-loader-registration.c
+++ b/gplugin/tests/test-loader-registration.c
@@ -73,7 +73,7 @@
 G_DEFINE_TYPE(TestGPluginLoader, test_gplugin_loader, GPLUGIN_TYPE_LOADER)
 
 static void
-test_gplugin_loader_init(TestGPluginLoader *loader)
+test_gplugin_loader_init(G_GNUC_UNUSED TestGPluginLoader *loader)
 {
 }
 
diff --git a/gplugin/tests/test-loader.c b/gplugin/tests/test-loader.c
--- a/gplugin/tests/test-loader.c
+++ b/gplugin/tests/test-loader.c
@@ -51,7 +51,7 @@
 };
 
 static void
-test_gplugin_plugin_iface_init(GPluginPluginInterface *iface)
+test_gplugin_plugin_iface_init(G_GNUC_UNUSED GPluginPluginInterface *iface)
 {
 }
 
@@ -136,7 +136,7 @@
 }
 
 static void
-test_gplugin_plugin_init(TestGPluginPlugin *plugin)
+test_gplugin_plugin_init(G_GNUC_UNUSED TestGPluginPlugin *plugin)
 {
 }
 
@@ -229,7 +229,7 @@
 G_DEFINE_TYPE(TestGPluginLoader, test_gplugin_loader, GPLUGIN_TYPE_LOADER)
 
 static void
-test_gplugin_loader_init(TestGPluginLoader *loader)
+test_gplugin_loader_init(G_GNUC_UNUSED TestGPluginLoader *loader)
 {
 }
 
diff --git a/gplugin/tests/test-versioned-dependencies.c b/gplugin/tests/test-versioned-dependencies.c
--- a/gplugin/tests/test-versioned-dependencies.c
+++ b/gplugin/tests/test-versioned-dependencies.c
@@ -23,7 +23,7 @@
  * Helpers
  *****************************************************************************/
 static void
-_test_plugin_loaded(GPluginPlugin *dependent, const gchar *id)
+_test_plugin_loaded(G_GNUC_UNUSED GPluginPlugin *dependent, const gchar *id)
 {
 	GPluginManager *manager = gplugin_manager_get_default();
 	GPluginPlugin *plugin = NULL;
diff --git a/lua/gplugin-lua-loader.c b/lua/gplugin-lua-loader.c
--- a/lua/gplugin-lua-loader.c
+++ b/lua/gplugin-lua-loader.c
@@ -29,10 +29,7 @@
 	GPluginLoader parent;
 };
 
-G_DEFINE_DYNAMIC_TYPE(
-	GPluginLuaLoader,
-	gplugin_lua_loader,
-	GPLUGIN_TYPE_LOADER);
+G_DEFINE_DYNAMIC_TYPE(GPluginLuaLoader, gplugin_lua_loader, GPLUGIN_TYPE_LOADER)
 
 /******************************************************************************
  * Helpers
@@ -126,7 +123,7 @@
 
 static gboolean
 gplugin_lua_loader_load(
-	GPluginLoader *loader,
+	G_GNUC_UNUSED GPluginLoader *loader,
 	GPluginPlugin *plugin,
 	GError **error)
 {
@@ -157,7 +154,7 @@
 
 static gboolean
 gplugin_lua_loader_unload(
-	GPluginLoader *loader,
+	G_GNUC_UNUSED GPluginLoader *loader,
 	GPluginPlugin *plugin,
 	gboolean shutdown,
 	GError **error)
diff --git a/lua/gplugin-lua-plugin.c b/lua/gplugin-lua-plugin.c
--- a/lua/gplugin-lua-plugin.c
+++ b/lua/gplugin-lua-plugin.c
@@ -60,7 +60,7 @@
 	gplugin_lua_plugin,
 	G_TYPE_OBJECT,
 	0,
-	G_IMPLEMENT_INTERFACE(GPLUGIN_TYPE_PLUGIN, gplugin_lua_plugin_iface_init));
+	G_IMPLEMENT_INTERFACE(GPLUGIN_TYPE_PLUGIN, gplugin_lua_plugin_iface_init))
 
 /******************************************************************************
  * GPluginPlugin Implementation
diff --git a/meson.build b/meson.build
--- a/meson.build
+++ b/meson.build
@@ -79,6 +79,10 @@
 	endif
 endif
 
+if compiler.has_argument('-Wextra')
+	add_project_arguments('-Wextra', language : 'c')
+endif
+
 toplevel_inc = include_directories('.')
 
 ###############################################################################
diff --git a/python3/gplugin-python3-loader.c b/python3/gplugin-python3-loader.c
--- a/python3/gplugin-python3-loader.c
+++ b/python3/gplugin-python3-loader.c
@@ -34,7 +34,7 @@
 G_DEFINE_DYNAMIC_TYPE(
 	GPluginPython3Loader,
 	gplugin_python3_loader,
-	GPLUGIN_TYPE_LOADER);
+	GPLUGIN_TYPE_LOADER)
 
 /******************************************************************************
  * GPluginLoader Implementation
diff --git a/python3/gplugin-python3-plugin.c b/python3/gplugin-python3-plugin.c
--- a/python3/gplugin-python3-plugin.c
+++ b/python3/gplugin-python3-plugin.c
@@ -68,7 +68,7 @@
 	0,
 	G_IMPLEMENT_INTERFACE(
 		GPLUGIN_TYPE_PLUGIN,
-		gplugin_python3_plugin_iface_init));
+		gplugin_python3_plugin_iface_init))
 
 /******************************************************************************
  * GPluginPlugin Implementation
