From 34e17b242467857233b94bcc00e71e1f104a2bd3 Mon Sep 17 00:00:00 2001 From: Joel Brobecker Date: Mon, 28 Jun 2004 18:59:14 +0000 Subject: [PATCH] * ada-lang.c: Re-indent file, with some massaging to help indent a bit when the result is otherwise really too ugly. --- gdb/ChangeLog | 5 +++++ gdb/ada-lang.c | 54 +++++++++++++++++++++++------------------------------- 2 files changed, 28 insertions(+), 31 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index fa149f3409..ae7e0b5dbe 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2004-06-28 Joel Brobecker + + * ada-lang.c: Re-indent file, with some massaging to help indent + a bit when the result is otherwise really too ugly. + 2004-06-27 Ulrich Weigand * frame.h (struct frame_id): Change bit field type of stack_addr_p, diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index 183e8aed37..57f3733319 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -993,8 +993,9 @@ ada_decode (const char *encoded) for (k = 0; ada_opname_table[k].encoded != NULL; k += 1) { int op_len = strlen (ada_opname_table[k].encoded); - if (strncmp (ada_opname_table[k].encoded + 1, encoded + i + 1, - op_len - 1) == 0 && !isalnum (encoded[i + op_len])) + if ((strncmp (ada_opname_table[k].encoded + 1, encoded + i + 1, + op_len - 1) == 0) + && !isalnum (encoded[i + op_len])) { strcpy (decoded + j, ada_opname_table[k].decoded); at_start_name = 0; @@ -2688,11 +2689,10 @@ resolve_subexp (struct expression **expp, int *pos, int deprocedure_p, else if (deprocedure_p && !is_nonfunction (candidates, n_candidates)) { - i = ada_resolve_function (candidates, n_candidates, NULL, 0, - SYMBOL_LINKAGE_NAME (exp-> - elts[pc + - 2].symbol), - context_type); + i = ada_resolve_function + (candidates, n_candidates, NULL, 0, + SYMBOL_LINKAGE_NAME (exp->elts[pc + 2].symbol), + context_type); if (i < 0) error ("Could not find a match for %s", SYMBOL_PRINT_NAME (exp->elts[pc + 2].symbol)); @@ -2740,13 +2740,11 @@ resolve_subexp (struct expression **expp, int *pos, int deprocedure_p, i = 0; else { - i = ada_resolve_function (candidates, n_candidates, - argvec, nargs, - SYMBOL_LINKAGE_NAME (exp-> - elts[pc + - 5]. - symbol), - context_type); + i = ada_resolve_function + (candidates, n_candidates, + argvec, nargs, + SYMBOL_LINKAGE_NAME (exp->elts[pc + 5].symbol), + context_type); if (i < 0) error ("Could not find a match for %s", SYMBOL_PRINT_NAME (exp->elts[pc + 5].symbol)); @@ -3097,9 +3095,9 @@ user_select_syms (struct ada_symbol_info *syms, int nsyms, int max_results) find_function_start_sal (syms[i].sym, 1); printf_unfiltered ("[%d] %s at %s:%d\n", i + first_choice, SYMBOL_PRINT_NAME (syms[i].sym), - sal.symtab == - NULL ? "" : sal. - symtab->filename, sal.line); + (sal.symtab == NULL + ? "" + : sal.symtab->filename), sal.line); continue; } else @@ -6994,13 +6992,10 @@ ada_search_struct_field (char *name, struct value *arg, int offset, else if (ada_is_wrapper_field (type, i)) { - struct value *v = ada_search_struct_field (name, arg, - offset + - TYPE_FIELD_BITPOS (type, - i) / - 8, - TYPE_FIELD_TYPE (type, - i)); + struct value *v = /* Do not let indent join lines here. */ + ada_search_struct_field (name, arg, + offset + TYPE_FIELD_BITPOS (type, i) / 8, + TYPE_FIELD_TYPE (type, i)); if (v != NULL) return v; } @@ -7013,13 +7008,10 @@ ada_search_struct_field (char *name, struct value *arg, int offset, for (j = TYPE_NFIELDS (field_type) - 1; j >= 0; j -= 1) { - struct value *v = ada_search_struct_field (name, arg, - var_offset - + - TYPE_FIELD_BITPOS - (field_type, j) / 8, - TYPE_FIELD_TYPE - (field_type, j)); + struct value *v = ada_search_struct_field /* Force line break. */ + (name, arg, + var_offset + TYPE_FIELD_BITPOS (field_type, j) / 8, + TYPE_FIELD_TYPE (field_type, j)); if (v != NULL) return v; } -- 2.11.0