Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Jul 2006 10:16:28 -0600 (MDT)
From:      "M. Warner Losh" <imp@bsdimp.com>
To:        mag@intron.ac
Cc:        des@des.no, delphij@delphij.net, julian@elischer.org, freebsd-hackers@freebsd.org
Subject:   Re: kern/99979: Get Ready for Kernel Module in C++
Message-ID:  <20060711.101628.1678774797.imp@bsdimp.com>
In-Reply-To: <1152612305.19369@origin.intron.ac>
References:  <courier.44B35DBC.00003F75@intron.ac> <86fyh8zgw8.fsf@xps.des.no> <1152612305.19369@origin.intron.ac>

next in thread | previous in thread | raw e-mail | index | archive | help
In message: <1152612305.19369@origin.intron.ac>
            mag@intron.ac writes:
: >> --- systm.h.orig	Mon Jul 10 05:42:58 2006
: >> +++ systm.h	Mon Jul 10 18:44:01 2006
: >> @@ -203,7 +203,7 @@
: >>  int	suword16(void *base, int word);
: >>  int	suword32(void *base, int32_t word);
: >>  int	suword64(void *base, int64_t word);
: >> -intptr_t casuptr(intptr_t *p, intptr_t old, intptr_t new);
: >> +intptr_t casuptr(intptr_t *p, intptr_t old, intptr_t __new__);
: > 
: > This is a namespace violation.  A simpler solution is to leave out
: > argument names entirely.
: 
: If the code style permits, I agree with you.
: 
: GCC support library usually uses "namespace" to add various prefixes
: to its built-in functions/variables in order to avoid conflicts against
: user code. In ELF binary file, built-in functions/variables' names are
: much longer than "__new__". See files in
: /usr/src/contrib/libstdc++/libsupc++/.

__new__ is bogus.  _new if you must.

Warner



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060711.101628.1678774797.imp>