[gnome-builder] clang: avoid unncessary cast when building completion list



commit 138f61ced312c1fc3eda0e7e3c306bbb2b270ae0
Author: Christian Hergert <chergert redhat com>
Date:   Mon Nov 20 17:27:30 2017 -0800

    clang: avoid unncessary cast when building completion list

 src/plugins/clang/ide-clang-translation-unit.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)
---
diff --git a/src/plugins/clang/ide-clang-translation-unit.c b/src/plugins/clang/ide-clang-translation-unit.c
index ea8fa9e..6dc1bd0 100644
--- a/src/plugins/clang/ide-clang-translation-unit.c
+++ b/src/plugins/clang/ide-clang-translation-unit.c
@@ -705,12 +705,7 @@ ide_clang_translation_unit_code_complete_worker (GTask        *task,
   ar = g_ptr_array_new_with_free_func (g_object_unref);
 
   for (i = 0; i < results->NumResults; i++)
-    {
-      GtkSourceCompletionProposal *proposal;
-
-      proposal = GTK_SOURCE_COMPLETION_PROPOSAL (ide_clang_completion_item_new (refptr, i));
-      g_ptr_array_add (ar, proposal);
-    }
+    g_ptr_array_add (ar, ide_clang_completion_item_new (refptr, i));
 
   g_task_return_pointer (task, ar, (GDestroyNotify)g_ptr_array_unref);
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]