lkml.org 
[lkml]   [2023]   [Aug]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v1 3/4] lib/vsprintf: Remove implied inclusions
From
On 04/08/2023 10.26, Andy Shevchenko wrote:
> Remove inclusions that are implied and guaranteed to be provided by others:
>
> compiler.h by types.h
> string.hi by string_helpers.h

What? No. That's not what we want. Each .c and each .h file should
include the headers that declare the stuff they're using. So if
string_helpers.h magically stops referring to anything from string.h,
one should be allowed to stop including string.h from string_helpers.h.

Sure, those two may forever be so intertwined that it never happens, but
one really can't maintain some matrix of "X always includes Y so if you
include X you don't have to include Y" in one's head.

Rasmus

\
 
 \ /
  Last update: 2023-08-04 11:36    [W:0.088 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site