lkml.org 
[lkml]   [2019]   [Aug]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] kbuild: detect missing header include guard
Hi Masahiro

On Mon, Jul 29, 2019 at 02:34:45AM +0900, Masahiro Yamada wrote:
> Our convention is to surround the whole of the header content with an
> include guard. This avoids the same header being parsed over again in
> case it is included multiple times.
>
> The include guard is missing in several places, or broken due to the
> mismatch between #ifndef and #define.
>
> The recently added header-test-y syntax allows the comprehensive sanity
> checks of headers. This commit adds another check; if include guard is
> missing, the header will fail to build due to redefinition of something.
>
> Some headers must be excluded from the test-coverage for now. I will
> let them in after they are fixed.

Smart and simple - nice.

>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>

Sam

\
 
 \ /
  Last update: 2019-08-10 08:40    [W:0.142 / U:0.080 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site