Fix big-endian aggregate assignment in Ada
authorTom Tromey <tromey@adacore.com>
Fri, 26 Apr 2019 16:57:52 +0000 (10:57 -0600)
committerTom Tromey <tromey@adacore.com>
Wed, 1 May 2019 14:09:22 +0000 (08:09 -0600)
commitd48e62f4a263a871b7a62793e8000625735bc2f6
treed5e30d500bccde97f8d27793cd6d3fe0d77e83f4
parent25a0274483cb00c27945b0337005be4f169ff09f
Fix big-endian aggregate assignment in Ada

A bug internal to AdaCore notes that assigning a non-scalar value to
an element of a packed array will sometimes fail.

The bug turns out to be that ada_value_assign incorrectly computes the
starting point for the assignment.  This patch fixes the problem.

gdb/ChangeLog
2019-05-01  Tom Tromey  <tromey@adacore.com>

* ada-lang.c (ada_value_assign): Correctly compute starting offset
for big-endian copies.

gdb/testsuite/ChangeLog
2019-05-01  Tom Tromey  <tromey@adacore.com>

* gdb.ada/packed_array_assign.exp: Add packed assignment
regression test.
gdb/ChangeLog
gdb/ada-lang.c
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.ada/packed_array_assign.exp
This page took 0.028462 seconds and 4 git commands to generate.