Re: [PATCH 14/15] cleanup: move parsing helpers to parse.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Jul 5, 2020 at 6:02 AM Luc Van Oostenryck
<luc.vanoostenryck@xxxxxxxxx> wrote:
>
> lib.c contains 2-3 helpers for parsing. Move them to parse.c.

This makes sense, because it's not a "library" function if it's only
used in one place.

HOWEVER.

When doing things like this, please also mark the resulting function
static and remove the declaration from lib.h.

Otherwise it's entirely pointless, I feel.

Either it's a library function that gets used from other places (and
lib.c/lib.h is an appropriate place), or it's a parsing-only helper
function that _doesn't_ get used from other places (and it should be
moved to parse.c and be static).

Not this half-way state that this patch seems to create.

               Linus



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux