bug-gnulib
[Top][All Lists]
Advanced

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

Re: [PATCH] Added a module stringops that provides STREQ and STRNEQ


From: Eric Blake
Subject: Re: [PATCH] Added a module stringops that provides STREQ and STRNEQ
Date: Wed, 21 May 2014 22:31:42 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0

On 05/21/2014 09:33 PM, Kieran Colford wrote:
> ---
>  lib/stringops.h   |   31 +++++++++++++++++++++++++++++++
>  modules/stringops |   22 ++++++++++++++++++++++
>  2 files changed, 53 insertions(+)
>  create mode 100644 lib/stringops.h
>  create mode 100644 modules/stringops

Your commit message isn't quite up to par.  Write in present tense, not
past tense, and make the subject line short (put the details in the rest
of the commit message).  Maybe:

stringops: add new module

maint.mk has long had a syntax-check rule that requests that users use
STREQ (a, b) instead of open-coding (strcmp (a, b) == 0); but nothing in
gnulib actually provided that macro.  This adds a new module to provide
it, and a counterpart STRNEQ.

> 
> diff --git a/lib/stringops.h b/lib/stringops.h
> new file mode 100644
> index 0000000..459889c
> --- /dev/null
> +++ b/lib/stringops.h
> @@ -0,0 +1,31 @@
> +/* Compile-time assert-like macros.
> +

Stale comment (too much copy and paste).


> +++ b/modules/stringops
> @@ -0,0 +1,22 @@
> +Description:
> +Add the macros STREQ and STRNEQ.  This adds the functionality that is
> +looked for by sc_prohibit_strcmp from the maintainer-makefile.

This is a bit long; maybe:

Add useful macros for common string operations.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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