diff options
author | Keith Seitz <keiths@redhat.com> | 2012-09-12 23:29:05 +0000 |
---|---|---|
committer | Keith Seitz <keiths@redhat.com> | 2012-09-12 23:29:05 +0000 |
commit | ea3a9873f8764bacd0e654ec390de0b235bc2bd8 (patch) | |
tree | bfc7c36cd0c4fbf9231d57eea9a4e014819885c8 | |
parent | 31c766788ab7bac89042ba4ff0095aeed0fe8b77 (diff) | |
download | fsf-binutils-gdb-ea3a9873f8764bacd0e654ec390de0b235bc2bd8.zip fsf-binutils-gdb-ea3a9873f8764bacd0e654ec390de0b235bc2bd8.tar.gz fsf-binutils-gdb-ea3a9873f8764bacd0e654ec390de0b235bc2bd8.tar.bz2 |
* gdb.cp/converts.cc (main): Comment out the pointer to boolean
conversion statement.
-rw-r--r-- | gdb/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/testsuite/gdb.cp/converts.cc | 8 |
2 files changed, 13 insertions, 0 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 7b1dc36..faefb8d 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2012-09-12 Keith Seitz <keiths@redhat.com> + + * gdb.cp/converts.cc (main): Comment out the pointer to boolean + conversion statement. + 2012-09-12 Doug Evans <dje@google.com> * gdb.base/help.exp: Remove testing of individual command help text, diff --git a/gdb/testsuite/gdb.cp/converts.cc b/gdb/testsuite/gdb.cp/converts.cc index 1cda43d..025123f 100644 --- a/gdb/testsuite/gdb.cp/converts.cc +++ b/gdb/testsuite/gdb.cp/converts.cc @@ -78,7 +78,15 @@ int main() foo1_7 (long_int); // long to boolean foo1_7 (*a); // char to boolean foo1_7 (MY_A); // unscoped enum to boolean + /* converts.exp tests the next statement directly. It is not compiled + here for verification because older versions of GCC (~4.1) fail to + compile it: + + warning: the address of 'int foo1_7(bool)' will always evaluate as true + foo1_7 (&foo1_7); // pointer to boolean + */ + foo1_7 (&A::member_); // pointer to member to boolean foo1_7 (a); // pointer to boolean foo1_7 (fp); // float to boolean |