This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [commit] Deprecate remaining STREQ uses


On Tue, 25 Nov 2003 12:54:15 -0500, Andrew Cagney <cagney@gnu.org> said:

> So, should the transformation be the strictly mechanical inline expansion:

>    STREQ(a,b) =>  (*(a) == *(b) ? !strcmp ((a), (b)) : 0)

> or also include a simplification leading to:

>    STREQ(a,b) => (strcmp ((a), (b)) == 0)

I would vote for the latter.  It should be easy to do mechanically via
keyboard macros, and it's how we would prefer the code to look.

David Carlton
carlton@kealia.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]