[gnome-builder] build: fix a number of compiler warnings on Clang
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] build: fix a number of compiler warnings on Clang
- Date: Wed, 14 Sep 2022 21:23:54 +0000 (UTC)
commit 6b67fcd08fd3bd2a50d36c1f5960ef434d10520e
Author: Christian Hergert <christian hergert me>
Date: Wed Sep 14 14:23:46 2022 -0700
build: fix a number of compiler warnings on Clang
Clang does a better job of finding unused functions which are also using
__attribute__(cleanup...) but no actual use other than that.
src/libide/foundry/ide-device-manager.c | 1 -
src/libide/foundry/ide-pipeline.c | 2 --
src/libide/foundry/ide-run-command-provider.c | 13 -------------
src/plugins/cargo/gbp-cargo-pipeline-addin.c | 3 ---
src/plugins/grep/gbp-grep-workspace-addin.c | 1 -
src/plugins/meson/gbp-meson-build-target-provider.c | 4 ----
src/plugins/meson/gbp-meson-run-command-provider.c | 1 -
src/plugins/todo/gbp-todo-model.c | 1 -
src/plugins/vala-indenter/ide-vala-indenter.c | 1 -
9 files changed, 27 deletions(-)
---
diff --git a/src/libide/foundry/ide-device-manager.c b/src/libide/foundry/ide-device-manager.c
index dab85cd5b..d2b616615 100644
--- a/src/libide/foundry/ide-device-manager.c
+++ b/src/libide/foundry/ide-device-manager.c
@@ -352,7 +352,6 @@ ide_device_manager_add_local (IdeDeviceManager *self)
{
g_autoptr(IdeDevice) device = NULL;
g_autoptr(IdeTriplet) triplet = NULL;
- g_autofree gchar *arch = NULL;
g_return_if_fail (IDE_IS_DEVICE_MANAGER (self));
diff --git a/src/libide/foundry/ide-pipeline.c b/src/libide/foundry/ide-pipeline.c
index d16aa4371..e5dcf205f 100644
--- a/src/libide/foundry/ide-pipeline.c
+++ b/src/libide/foundry/ide-pipeline.c
@@ -1062,7 +1062,6 @@ static void
register_build_commands_stage (IdePipeline *self,
IdeContext *context)
{
- g_autoptr(GError) error = NULL;
const gchar * const *build_commands;
g_autofree gchar *rundir_path = NULL;
GFile *rundir;
@@ -1114,7 +1113,6 @@ static void
register_post_install_commands_stage (IdePipeline *self,
IdeContext *context)
{
- g_autoptr(GError) error = NULL;
const gchar * const *post_install_commands;
g_assert (IDE_IS_PIPELINE (self));
diff --git a/src/libide/foundry/ide-run-command-provider.c b/src/libide/foundry/ide-run-command-provider.c
index 72bff4af2..5b7e247ea 100644
--- a/src/libide/foundry/ide-run-command-provider.c
+++ b/src/libide/foundry/ide-run-command-provider.c
@@ -97,19 +97,6 @@ ide_run_command_provider_invalidate (IdeRunCommandProvider *self)
g_signal_emit (self, signals[INVALIDATED], 0);
}
-static inline gulong
-get_signal_handler (IdeRunCommandProvider *self)
-{
- return GPOINTER_TO_SIZE (g_object_get_data (G_OBJECT (self), "INVALIDATES_AT_PHASE"));
-}
-
-static inline void
-set_signal_handler (IdeRunCommandProvider *self,
- gulong handler_id)
-{
- g_object_set_data (G_OBJECT (self), "INVALIDATES_AT_PHASE", GSIZE_TO_POINTER (handler_id));
-}
-
static void
ide_run_command_provider_pipeline_notify_phase_cb (IdeRunCommandProvider *self,
GParamSpec *pspec,
diff --git a/src/plugins/cargo/gbp-cargo-pipeline-addin.c b/src/plugins/cargo/gbp-cargo-pipeline-addin.c
index 320e161fc..eb9cd021c 100644
--- a/src/plugins/cargo/gbp-cargo-pipeline-addin.c
+++ b/src/plugins/cargo/gbp-cargo-pipeline-addin.c
@@ -136,9 +136,6 @@ gbp_cargo_pipeline_addin_load (IdePipelineAddin *addin,
IdePipeline *pipeline)
{
GbpCargoPipelineAddin *self = (GbpCargoPipelineAddin *)addin;
- g_autoptr(IdeSubprocessLauncher) fetch_launcher = NULL;
- g_autoptr(IdeSubprocessLauncher) build_launcher = NULL;
- g_autoptr(IdeSubprocessLauncher) clean_launcher = NULL;
g_autoptr(IdeRunContext) fetch_context = NULL;
g_autoptr(IdeRunContext) build_context = NULL;
g_autoptr(IdeRunContext) clean_context = NULL;
diff --git a/src/plugins/grep/gbp-grep-workspace-addin.c b/src/plugins/grep/gbp-grep-workspace-addin.c
index f08de63a0..f2cec2a8b 100644
--- a/src/plugins/grep/gbp-grep-workspace-addin.c
+++ b/src/plugins/grep/gbp-grep-workspace-addin.c
@@ -57,7 +57,6 @@ gbp_grep_workspace_addin_load (IdeWorkspaceAddin *addin,
IdeWorkspace *workspace)
{
GbpGrepWorkspaceAddin *self = (GbpGrepWorkspaceAddin *)addin;
- g_autoptr(GSimpleActionGroup) group = NULL;
g_autoptr(PanelPosition) position = NULL;
g_assert (GBP_IS_GREP_WORKSPACE_ADDIN (self));
diff --git a/src/plugins/meson/gbp-meson-build-target-provider.c
b/src/plugins/meson/gbp-meson-build-target-provider.c
index 116e2c54e..78a2934e0 100644
--- a/src/plugins/meson/gbp-meson-build-target-provider.c
+++ b/src/plugins/meson/gbp-meson-build-target-provider.c
@@ -61,8 +61,6 @@ gbp_meson_build_target_provider_communicate_cb (GObject *object,
g_autofree gchar *stdout_buf = NULL;
g_autoptr(IdeTask) task = user_data;
g_autoptr(JsonParser) parser = NULL;
- g_autoptr(IdeSubprocessLauncher) launcher = NULL;
- g_autoptr(IdeSubprocess) all_subprocess = NULL;
g_autoptr(GError) error = NULL;
g_autoptr(GPtrArray) ret = NULL;
g_autoptr(GFile) builddir = NULL;
@@ -137,9 +135,7 @@ gbp_meson_build_target_provider_communicate_cb (GObject *object,
NULL != (type = json_node_get_string (member)))
{
g_autoptr(IdeBuildTarget) target = NULL;
- g_autofree char *install_dir = NULL;
g_autofree char *base = NULL;
- g_autofree char *name_of_dir = NULL;
g_autofree char *dir_path = NULL;
g_autoptr(GFile) file = NULL;
g_autoptr(GFile) dir = NULL;
diff --git a/src/plugins/meson/gbp-meson-run-command-provider.c
b/src/plugins/meson/gbp-meson-run-command-provider.c
index d166bcef2..dbd07a1fb 100644
--- a/src/plugins/meson/gbp-meson-run-command-provider.c
+++ b/src/plugins/meson/gbp-meson-run-command-provider.c
@@ -64,7 +64,6 @@ gbp_meson_run_command_provider_list_commands_async (IdeRunCommandProvider *provi
gpointer user_data)
{
GbpMesonRunCommandProvider *self = (GbpMesonRunCommandProvider *)provider;
- g_autoptr(GListModel) run_commands = NULL;
GbpMesonIntrospection *introspection;
g_autoptr(IdeTask) task = NULL;
IdePipelineAddin *addin;
diff --git a/src/plugins/todo/gbp-todo-model.c b/src/plugins/todo/gbp-todo-model.c
index 01a1d432f..5cb5971c7 100644
--- a/src/plugins/todo/gbp-todo-model.c
+++ b/src/plugins/todo/gbp-todo-model.c
@@ -378,7 +378,6 @@ gbp_todo_model_mine_worker (IdeTask *task,
g_autoptr(GError) error = NULL;
g_autoptr(GSequence) items = NULL;
g_autoptr(GbpTodoItem) item = NULL;
- g_autoptr(GListStore) store = NULL;
g_autoptr(GBytes) bytes = NULL;
g_autoptr(GTimer) timer = g_timer_new ();
g_autofree char *workpath = NULL;
diff --git a/src/plugins/vala-indenter/ide-vala-indenter.c b/src/plugins/vala-indenter/ide-vala-indenter.c
index b01d27b85..20fc0f24d 100644
--- a/src/plugins/vala-indenter/ide-vala-indenter.c
+++ b/src/plugins/vala-indenter/ide-vala-indenter.c
@@ -390,7 +390,6 @@ vala_indent (GtkSourceIndenter *self,
gboolean found_closing_brace = FALSE;
g_autofree char *reference_indent = NULL;
g_autofree char *indent1 = NULL;
- g_autofree char *extension = NULL;
g_autofree char *full = NULL;
GtkTextIter old = {0};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]