diff options
| author | Cyrille Bagard <nocbos@gmail.com> | 2016-12-15 13:48:06 (GMT) | 
|---|---|---|
| committer | Cyrille Bagard <nocbos@gmail.com> | 2016-12-15 13:48:06 (GMT) | 
| commit | 12ebd5475a71466e7a9f3dc07a3f312e25bf639f (patch) | |
| tree | a38e980bc4947f890b81d3b4dd1264c99e6f9bf6 | |
| parent | 124c8410dbfcad59d66b850c50c96ec73a607ab7 (diff) | |
Removed dead code.
| -rw-r--r-- | ChangeLog | 9 | ||||
| -rw-r--r-- | src/arch/instruction.c | 48 | ||||
| -rw-r--r-- | src/arch/instruction.h | 6 | ||||
| -rw-r--r-- | src/gui/menus/edition.c | 8 | 
4 files changed, 11 insertions, 60 deletions
| @@ -1,5 +1,14 @@  16-12-15  Cyrille Bagard <nocbos@gmail.com> +	* src/arch/instruction.c: +	* src/arch/instruction.h: +	Remove dead code. + +	* src/gui/menus/edition.c: +	Update comments. + +16-12-15  Cyrille Bagard <nocbos@gmail.com> +  	* plugins/androhelpers/params.c:  	* plugins/androhelpers/switch.c:  	* plugins/androhelpers/try_n_catch.c: diff --git a/src/arch/instruction.c b/src/arch/instruction.c index 7106631..5f35db4 100644 --- a/src/arch/instruction.c +++ b/src/arch/instruction.c @@ -983,25 +983,6 @@ GBufferLine *g_arch_instruction_print(const GArchInstruction *instr, GCodeBuffer  /******************************************************************************  *                                                                             * -*  Paramètres  : list = liste d'instructions à consulter.                     * -*                                                                             * -*  Description : Renvoie vers la dernière instruction d'une série.            * -*                                                                             * -*  Retour      : Dernière instruction trouvée (ou NULL ?!).                   * -*                                                                             * -*  Remarques   : -                                                            * -*                                                                             * -******************************************************************************/ - -GArchInstruction *g_arch_instruction_find_last(const GArchInstruction *list) -{ -    return ainstr_list_last(list); - -} - - -/****************************************************************************** -*                                                                             *  *  Paramètres  : list  = liste d'instructions à compléter, ou NULL.           *  *                instr = nouvelle instruction à intégrer à l'ensemble.        *  *                                                                             * @@ -1098,35 +1079,6 @@ GArchInstruction *g_arch_instruction_get_next_iter(const GArchInstruction *list,  /******************************************************************************  *                                                                             * -*  Paramètres  : list  = liste de lignes à parcourir.                         * -*                range = emplacement mémoire à comparer.                      * -*                                                                             * -*  Description : Recherche une instruction d'après son emplacement mémoire.   * -*                                                                             * -*  Retour      : Instruction trouvée à l'adresse donnée, NULL si aucune.      * -*                                                                             * -*  Remarques   : -                                                            * -*                                                                             * -******************************************************************************/ - -GArchInstruction *g_arch_instruction_find_by_range(GArchInstruction *list, const mrange_t *range) -{ -    GArchInstruction *result;               /* Trouvaille à retourner      */ - -    ainstr_list_for_each(result, list) -    { -        if (cmp_mrange(&result->range, range) == 0) -            break; - -    } - -    return result; - -} - - -/****************************************************************************** -*                                                                             *  *  Paramètres  : list   = liste de lignes à parcourir.                        *  *                addr   = position en mémoire ou physique à chercher.         *  *                strict = définit la considération à porter à l'adresse.      * diff --git a/src/arch/instruction.h b/src/arch/instruction.h index bddc2bf..54778b5 100644 --- a/src/arch/instruction.h +++ b/src/arch/instruction.h @@ -230,9 +230,6 @@ GBufferLine *g_arch_instruction_print(const GArchInstruction *, GCodeBuffer *, M  /* -------------------- TRAITEMENT DES INSTRUCTIONS PAR ENSEMBLE -------------------- */ -/* Renvoie vers la dernière instruction d'une série. */ -GArchInstruction *g_arch_instruction_find_last(const GArchInstruction *); -  /* Ajoute une instruction à un ensemble existant. */  void g_arch_instruction_add_to_list(GArchInstruction **, GArchInstruction *); @@ -245,9 +242,6 @@ GArchInstruction *g_arch_instruction_get_prev_iter(const GArchInstruction *, con  /* Fournit l'élement suivant un autre pour un parcours. */  GArchInstruction *g_arch_instruction_get_next_iter(const GArchInstruction *, const GArchInstruction *, vmpa_t); -/* Recherche une instruction d'après son emplacement mémoire. */ -GArchInstruction *g_arch_instruction_find_by_range(GArchInstruction *, const mrange_t *); -  /* Recherche une instruction d'après son adresse. */  GArchInstruction *g_arch_instruction_find_by_address(GArchInstruction *, const vmpa2t *, bool) __attribute__ ((deprecated));  /* -> g_arch_processor_find_instr_by_address */ diff --git a/src/gui/menus/edition.c b/src/gui/menus/edition.c index da2c60f..89b5fe9 100644 --- a/src/gui/menus/edition.c +++ b/src/gui/menus/edition.c @@ -513,12 +513,8 @@ static void mcb_edition_list_xrefs(GtkMenuItem *menuitem, GMenuBar *bar)           * être de taille nulle (cas d'une étiquette, par exemple), à la différence           * de la taille d'une instruction.           * -         * Il n'est donc pas judicieux de rechercher cette instruction avec -         * un appel de type : -         * -         *    instr = g_arch_instruction_find_by_range(list, range); -         * -         * Il faut ainsi être plus souple, et se baser sur l'adresse uniquement. +         * Il faut ainsi être plus souple, et se baser sur l'espace couvert par +         * une ligne mais sur l'adresse uniquement.           */          instr = g_arch_processor_find_instr_by_address(proc, get_mrange_addr(range)); | 
