diff options
author | Bruno Larsen <blarsen@redhat.com> | 2022-10-04 16:09:05 +0200 |
---|---|---|
committer | Bruno Larsen <blarsen@redhat.com> | 2022-10-31 13:43:56 +0100 |
commit | 1e7416363963e27c8d122bee2397d4b48a482ec3 (patch) | |
tree | dc0fb73b9815db2f40c4b564a66defccf2600c9d | |
parent | 2ce385da88704170ba6922743c437177eef2c09d (diff) | |
download | binutils-1e7416363963e27c8d122bee2397d4b48a482ec3.zip binutils-1e7416363963e27c8d122bee2397d4b48a482ec3.tar.gz binutils-1e7416363963e27c8d122bee2397d4b48a482ec3.tar.bz2 |
gdb/testsuite: fix gdb.cp/converts.exp to run with clang
Clang attempts to minimize the size of the debug-info by not adding
complete information about types that aren't constructed in a given
file. Specifically, this meant that there was minimal information about
class B in the test gdb.cp/converts.exp. To fix this, we just need to
construct any object of type B in that file.
Approved-By: Andrew Burgess <aburgess@redhat.com>
-rw-r--r-- | gdb/testsuite/gdb.cp/converts.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/testsuite/gdb.cp/converts.cc b/gdb/testsuite/gdb.cp/converts.cc index ecf8064..1224581 100644 --- a/gdb/testsuite/gdb.cp/converts.cc +++ b/gdb/testsuite/gdb.cp/converts.cc @@ -55,7 +55,7 @@ int main() char av = 'a'; char *a = &av; // pointer to.. - B *bp; + B *bp = new B(); foo1_1 (a); // ..pointer foo1_2 (a); // ..array foo1_3 ((int*)a); // ..pointer of wrong type |