Re: [PATCH] MdePkg: Add STATIC_ASSERT macro


Laszlo Ersek
 

(adding back the list)

On 08/13/19 16:30, vit9696@... wrote:
Laszlo,

GCC implemented _Static_assert in 4.6. See its official wiki for C11 compatibility documentation:

https://gcc.gnu.org/wiki/C11Status
Awesome news!

Once this is upstreamed, we should go through all the ASSERT()s in the
code, and replace those that are compile-time checkable with
STATIC_ASSERT(). I know that I've added quite a few ASSERT()s that I
wished would be checked at build time.

Of course, I'll probably never have time for that. :/

Thanks
Laszlo

Join devel@edk2.groups.io to automatically receive all group messages.