[Top][All Lists]

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

Re: [PATCH 0/1] Reduce footprint of xstrtol module

From: Bruno Haible
Subject: Re: [PATCH 0/1] Reduce footprint of xstrtol module
Date: Thu, 05 Dec 2019 22:56:08 +0100
User-agent: KMail/5.1.3 (Linux/4.4.0-166-generic; KDE/5.18.0; x86_64; ; )

Hi Pino,

> I decided to move xstrtol_fatal() to an own xstrtol-error module.
> This has the nice advantage to reduce the footprint a lot

That's a good move. Great!

> There are only two potential downsides:
> 1) users of the xstro* modules may use xstrtol_fatal() right now

Your mitigation, to mention it in the NEWS file, is sufficient.

> 2) some of the indirectly modules no more required can affect the
>    results of configure checks (for example the extensions module is no
>    more used)

Gnulib users must live with the fact that a module that they don't explicitly
ask for can silently go away from the set of imported modules.

One suggestion, though:

>  lib/xstrtol-error.h   | 45 +++++++++++++++++++++++++++++++++++++++++++
>  lib/xstrtol.h         | 20 -------------------

It is possible to have several modules share the same .h file. For example,
<math.h> is used by many modules. If you leave xstrtol.h as is, users of the
module don't need to change their source code, they only need to import the
new module 'xstrtol-error'.
A separate .h file, on the other hand, provides a more orthogonal code

I'm not suggesting one or the other. Just want to make sure you are aware
that you have a choice here, i.e. there's a trade-off.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]