OSDN Git Service

* eval.c (evaluate_subexp_standard): Fix type of result of mixed
authorDoug Evans <dje@google.com>
Mon, 4 Feb 2008 00:23:05 +0000 (00:23 +0000)
committerDoug Evans <dje@google.com>
Mon, 4 Feb 2008 00:23:05 +0000 (00:23 +0000)
commit55dcce129c60fa230b81b758d4dcc8ab8fd9cdb6
treead74e955a3db718a3d1d7dd60ee7a9cb18ded2fa
parentabc10851528ab324b577c776edbc05388b7f349f
* eval.c (evaluate_subexp_standard): Fix type of result of mixed
integer/float division operations when EVAL_AVOID_SIDE_EFFECTS.
* valops.c (value_one): New function.
* value.h (value_one): Declare.

Fix argument promotion for binary arithmetic ops for C.
* valarith.c (unop_result_type): New fn.
(binop_result_type): New fn.
(value_binop): Move result type computation to binop_result_type.
(value_pos, value_neg, value_complement): Move result type
computation to unop_result_type.

* gdb.base/whatis-exp.exp: Fix expected result of whatis x+y, x-y, x*y.
gdb/ChangeLog
gdb/eval.c
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/whatis-exp.exp
gdb/valarith.c
gdb/valops.c
gdb/value.h