On 03/27/2018 04:49 AM, Jakub Jelinek wrote:
Hi!

As the comment says, in a valid program we wals find thunk_binfo, but if the
covariancy is invalid, we've already diagnosed error and we might not find
it.  We have case to handle thunk_binfo NULL or not finding it in the chain,
but on the following testcase base_binfo is NULL and we ICE when we try to
access BINFO_TYPE on it.

Fixed thusly, furthermore to match the comment I've added an assertion that
if we don't find thunk_binfo we've indeed already diagnosed an error.

Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?

2018-03-27  Jakub Jelinek  <ja...@redhat.com>

        PR c++/85068
        * class.c (update_vtable_entry_for_fn): Don't ICE if base_binfo
        is NULL.  Assert if thunk_binfo is NULL then errorcount is non-zero.


ok, thanks.

nathan

--
Nathan Sidwell

Reply via email to