This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug c++/16959] gdb hangs in infinite recursion
- From: "jmdrouhard at gmail dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Thu, 03 Dec 2015 18:47:08 +0000
- Subject: [Bug c++/16959] gdb hangs in infinite recursion
- Auto-submitted: auto-generated
- References: <bug-16959-4717 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=16959
John Drouhard <jmdrouhard at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jmdrouhard at gmail dot com
Version|7.6 |7.10
--- Comment #2 from John Drouhard <jmdrouhard at gmail dot com> ---
I believe this is still an issue in 7.10. I am going to include a different
form of reproduceable than the original report has, and might actually indicate
a different bug. They are strikingly similar, though, so I'll include it here
first.
This form only reproduces the issue when using a typedef as the declared type
for the static member variable. It does NOT exhibit the issue if using the
class type explicitly. Using the typedef becomes desirable when class types
have multiple template parameters. See below:
class A {
typedef A type;
public:
bool operator==(const type& other) { return true; }
#ifdef SHOW_BUG
static const type INSTANCE;
#else
static const A INSTANCE;
#endif
};
const A A::INSTANCE;
int main() {
A a;
if (a == A::INSTANCE) {
return -1;
}
return 0;
}
--
You are receiving this mail because:
You are on the CC list for the bug.