I have a core dump and I am looking at the core dump with gdb.
I was wondering if there is a way to be able to examine the value of a boost::any value in gdb?
In the core, I had the address to the boost any and so I tried casting it to a placeholder to see if I could examine the value, but I fell short. I know that the type of the boost any is unsigned long so is there a way to view the any value knowing the type?
(gdb) print ('boost::any::placeholder')(*(('boost::any'*)0x00007f263fa27730).content)
warning: can't find linker symbol for virtual table for `boost::any::placeholder' value
warning: found `boost::any::holder<bool>::~holder()' instead
$129 = warning: can't find linker symbol for virtual table for `boost::any::placeholder' value
warning: found `boost::any::holder<bool>::~holder()' instead
warning: can't find linker symbol for virtual table for `boost::any::placeholder' value
warning: found `boost::any::holder<bool>::~holder()' instead
{
_vptr.placeholder = 0x7f2a9a662560
}
Any help with this matter would be much appreciated. Thanks!
boost::any
. After all, you don't even have to know the type of the content, since thevtable
pointer of the held type knows what the content type is. We need more gdb pretty printers! – Circumspect