On Wed, 24 Mar 2010 22:21:56 +0100 Magnus wrote:
MF> B)
MF> ---foo.h---
MF> #ifdef NETSNMP_DISABLE_FOO
MF> #define foo()
MF> #else
MF> extern void foo();
MF> #endif
MF> ---foo.c---
MF> #ifndef NETSNMP_DISABLE_FOO
MF> void foo() { /* do foo things */ }
MF> #endif

B, but I'd but the real function stuff at the top of the header, and have the
empty macros at the bottom. I don't want to have to scroll through the dummy
stuff to find what I'm looking for...

MF> C)
MF> ---foo.h---
MF> #ifndef NETSNMP_DISABLE_FOO
MF> extern void foo();
MF> #endif
MF> ---foo.c---
MF> #ifndef NETSNMP_DISABLE_FOO
MF> void foo() { /* do foo things */ }
MF> #endif

I also like C for internal things what wouldn't require lots of conditional
code in other files...

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to