apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Greg Stein <gst...@lyra.org>
Subject Re: [PATCH] Convenience macros for apr array manipulation
Date Sat, 13 Dec 2003 02:07:02 GMT
On Fri, Dec 12, 2003 at 04:38:53PM -0800, Roy T. Fielding wrote:
> >> +#define APR_ARRAY_PUSH(arr, type, item) \
> 
> A macro that is intended to mimic the behavior of a function call
> should always be named in the same way as function calls, not with
> all-uppercase names.  Stuff like the above makes the interface
> entirely dependent on the implementation, and makes the code harder
> to read for no reason.

It isn't mimic'ing a function call since you pass a type. Can't do that
with a function.

  APR_ARRAY_PUSH(arr, const char *, my_value);

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/

Mime
View raw message