A small patch for C++ VFS modules.
jra at samba.org
Thu Jun 23 21:07:25 GMT 2005
On Thu, Jun 23, 2005 at 10:02:28PM +1000, Ben Martin wrote:
> On Thu, 2005-06-23 at 15:38 +0400, Alexander Bokovoy wrote:
> > On Thu, Jun 23, 2005 at 05:15:52PM +1000, Ben Martin wrote:
> > > OK patch attached this time :/
> > Could you make it against current SVN for SAMBA_3_0? There were changes,
> > particulary in popt and VFS support which clutter your patch:
> OK, new patch against
> I have elected to make the "class" and "private" keywords conditional on
> if the code is being compiled with a C++ compiler. This makes the patch
> much less intrusive into the existing code and is less likely to annoy
> folks IMHO.
No - it's more annoying (IMHO) :-). I'd rather you change all uses of
these keywords over the entire source code (don't use leading underscores,
make the change more meaningful - leading underscores may be reserved for
use by the system). Can you give me a list of keywords you need to avoid ?
I'd rather fix this by doing :
#define class #error DONT_USE_C_PLUS_PLUS_KEYWORDS
#define template #error DONT_USE_C_PLUS_PLUS_KEYWORDS
then fix the code so everything compiles. Once that's done
we can surround these defines with an #ifndef __cplusplus
and we'll be done.
More information about the samba-technical