This is the mail archive of the
elfutils-devel@sourceware.org
mailing list for the elfutils project.
Re: [patch] Fix uninitialized Dwarf_Frame->regs
- From: Roland McGrath <roland at hack dot frob dot com>
- To: elfutils-devel at lists dot fedorahosted dot org
- Date: Mon, 08 Oct 2012 14:04:25 -0700
- Subject: Re: [patch] Fix uninitialized Dwarf_Frame->regs
> Do you mean plain assert? I would find this case more appropriate for static
> assertion, in GDB it is:
I did, but only because I didn't think we had a handy macro for static assert.
> In elfutils is already BUILD_BUG_ON_ZERO but only in "libebl/libeblP.h".
Move it into lib/system.h. For this kind of use, we should have one that
is warning-free when used as a statement, so add another macro if needed to
achieve that. That's better than a hack like:
> + bigger += BUILD_BUG_ON_ZERO (reg_unspecified);
Thanks,
Roland