This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: How to get more info about 'bad_function_call' ?
- From: "Linda A. Walsh" <gcc at tlinx dot org>
- To: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- Cc: libstdc++ <libstdc++ at gcc dot gnu dot org>
- Date: Tue, 27 Jan 2015 09:52:48 -0800
- Subject: Re: How to get more info about 'bad_function_call' ?
- Authentication-results: sourceware.org; auth=none
- References: <54C7A9F8 dot 70504 at tlinx dot org> <CAH6eHdQemyPo80Kq4g-tGvyqqvFrUP4jtPOLr8wyz_rAwfk__A at mail dot gmail dot com> <54C7C339 dot 5020401 at tlinx dot org> <CAH6eHdRGSV0p9zZPz4jjkGH0JJFHO4xjvHz1k9eeE8_L=MYEzQ at mail dot gmail dot com>
Jonathan Wakely wrote:
Just humour me and try assert( work != nullptr ) before the call to
work() where the exception gets thrown.
From the stack trace, that would be at ltask.cc:84
---
That's what I needed. I'd tried
if(f==(uint64_t) 0) and (f=NULL) and ((void *)f ==(void *)0)
all of which gave type conversion errors
---
nullptr was the bit that I was missing.
It may not be specific to libstc++ but it wasn't in 'C' that I remember.
I appreciate your patience and good natured replies! ;-)