From ee90b9ab362f9a71b990d15627271bd5bbe81668 Mon Sep 17 00:00:00 2001 From: Joel Brobecker Date: Wed, 15 Aug 2007 18:36:37 +0000 Subject: [PATCH] * ada-lang.c (possible_user_operator_p): Alternative fix to last checkin guarding against NULL. --- gdb/ChangeLog | 6 ++++++ gdb/ada-lang.c | 9 +-------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index bd452f2..73c794b 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2007-08-15 Paul Hilfinger + Joel Brobecker + + * ada-lang.c (possible_user_operator_p): Alternative fix to last + checkin guarding against NULL. + 2007-08-14 Michael Snyder * tui-command.c, tui-data.c, tui-disasm.c, tui-file.c, tui-io.c, diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index 4b1e292..7f96dea 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -3532,14 +3532,7 @@ possible_user_operator_p (enum exp_opcode op, struct value *args[]) return (!(scalar_type_p (type0) && scalar_type_p (type1))); case BINOP_CONCAT: - return - ((TYPE_CODE (type0) != TYPE_CODE_ARRAY - && (TYPE_CODE (type0) != TYPE_CODE_PTR - || TYPE_CODE (TYPE_TARGET_TYPE (type0)) != TYPE_CODE_ARRAY)) - || (type1 != NULL && TYPE_CODE (type1) != TYPE_CODE_ARRAY - && (TYPE_CODE (type1) != TYPE_CODE_PTR - || (TYPE_CODE (TYPE_TARGET_TYPE (type1)) - != TYPE_CODE_ARRAY)))); + return !ada_is_array_type (type0) || !ada_is_array_type (type1); case BINOP_EXP: return (!(numeric_type_p (type0) && integer_type_p (type1))); -- 2.7.4