This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix broken recursion detection when printing static members


On 2017-10-24 06:55, Patrick Frants wrote:
The fix shrinks the stack using obstack_blank_fast() with a negative
value as described at the bottom of this page:
https://gcc.gnu.org/onlinedocs/libiberty/Extra-Fast-Growing.html
"You can use obstack_blank_fast with a “negative” size argument to
make the current object smaller. Just don’t try to shrink it beyond
zero length—there’s no telling what will happen if you do that.
Earlier versions of obstacks allowed you to use obstack_blank to
shrink objects. This will no longer work."

A unit test (gdb.cp/printstaticrecursion.exp) was added. No new
regression has been observed in testsuite/gdb.cp/*.exp.

As mentioned in my last review, did you have a chance to see look if it was possible to improve the existing test about recursive static fields in gdb.cp/classes.exp, rather than introducing a new one?

Thanks,

Simon


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]