aboutsummaryrefslogtreecommitdiff
path: root/gdb/valops.c
diff options
context:
space:
mode:
authorUlrich Weigand <uweigand@de.ibm.com>2008-09-11 14:17:58 +0000
committerUlrich Weigand <uweigand@de.ibm.com>2008-09-11 14:17:58 +0000
commit22fe0fbb30429cd8f4f086a1da5d4821433e6a41 (patch)
tree8519e22fe2dfc4d366850b7a9cb3410097b80943 /gdb/valops.c
parentd8631d213f802a03c92513bb264b2f4ae65eb259 (diff)
downloadgdb-22fe0fbb30429cd8f4f086a1da5d4821433e6a41.zip
gdb-22fe0fbb30429cd8f4f086a1da5d4821433e6a41.tar.gz
gdb-22fe0fbb30429cd8f4f086a1da5d4821433e6a41.tar.bz2
* valops.c (value_ind): No longer allow dereferencing an
integer type. * eval.c (evaluate_subexp_standard): Handle deferencing an integer type here. * ada-lang.c (ada_evaluate_subexp): Likewise.
Diffstat (limited to 'gdb/valops.c')
-rw-r--r--gdb/valops.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/gdb/valops.c b/gdb/valops.c
index 0d1ffdf..f14c2f5 100644
--- a/gdb/valops.c
+++ b/gdb/valops.c
@@ -1172,14 +1172,7 @@ value_ind (struct value *arg1)
base_type = check_typedef (value_type (arg1));
- /* Allow * on an integer so we can cast it to whatever we want.
- This returns an int, which seems like the most C-like thing to
- do. "long long" variables are rare enough that
- BUILTIN_TYPE_LONGEST would seem to be a mistake. */
- if (TYPE_CODE (base_type) == TYPE_CODE_INT)
- return value_at_lazy (builtin_type_int,
- (CORE_ADDR) value_as_address (arg1));
- else if (TYPE_CODE (base_type) == TYPE_CODE_PTR)
+ if (TYPE_CODE (base_type) == TYPE_CODE_PTR)
{
struct type *enc_type;
/* We may be pointing to something embedded in a larger object.