Stas Bekman wrote:
Geoffrey Young wrote:
- if your wrapper calls directly the function, without doing anything else, but dropping "self" you should use DEFINE_, just in case compiler doesn't inline that call. I don't remember if it's in the doc.
re this an SvREFCNT_inc below, I figured it might be best to keep it as a separate function and not use define. in the patch below, the C function digs out the object, while the *.h wrapper calls the C function and increments the refcount before returning to Perl-land. sound ok?
but this can still be done in define:
#define ... SvREFCNT_inc(modperl_module_config_get(aTHX_ pmodule, s, v));
no?
yes, the below works (however, I was just following your advice wrt using #define to inline functions "without doing anything else" :)
I had to do the trickery with self to avoid unused variable warnings - lemme know if you have a better idea about that.
In that case your previous solution is probably the best, since it's most likely will be inlined in the final object anyways. I haven't though of this warning :(
plus indentation...
__________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
