|
From: | Paul Eggert |
Subject: | Re: [PATCH] Added a module stringops that provides STREQ and STRNEQ |
Date: | Wed, 21 May 2014 21:14:10 -0700 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 |
Kieran Colford wrote:
+#define STRNEQ(X, Y) (strcmp (X, Y) != 0)
1. This name is poorly chosen (it looks too much like "strncmp", which means something quite different) and it's not needed (people can just use "!STREQ").
2. STREQ should be an inline function, not a macro. There's little point to making it a macro.
3. STREQ's name should be lower case.
[Prev in Thread] | Current Thread | [Next in Thread] |