On Mon, Jun 03, 2013 at 08:00:58PM +, David Holland wrote:
> > #define__DECONST(t, a) const_cast(a)
>
> and I suppose one could also do something like this:
>
> #define __DECONST(t, v) \
>(sizeof((v) - (const t)0) ? (t)(unsigned long)(v) : 0)
Sounds good to me.
I seriously wonder w
On Sun, Jun 02, 2013 at 12:40:12AM +, Christos Zoulas wrote:
> > > > Log Message:
> > > > apply __UNCONST() if it exists.
> > >
> > > Reminds me: should/can __UNCONST() be revisited w.r.t. the thread below?
> > >
> > > http://lists.freebsd.org/pipermail/freebsd-arch/2013-May/014371.htm
On Mon, 03 Jun 2013, Christos Zoulas wrote:
| > Well, there is an advantage that the FreeBSD one has over ours. It can be
| > used in c++ with -Wold-style-cast, if defined as:
| >
| > #define __DECONST(t, a) const_cast(a)
|
| That, and why is it cast to an unsigned long and not uintptr_t?
So th
On Jun 3, 5:34am, jruoho...@iki.fi (Jukka Ruohonen) wrote:
-- Subject: Re: CVS commit: xsrc/external/mit/xauth/dist
| > Well, there is an advantage that the FreeBSD one has over ours. It can be
| > used in c++ with -Wold-style-cast, if defined as:
| >
| > #define __DECONST(t, a
On Sun, Jun 02, 2013 at 12:40:12AM +, Christos Zoulas wrote:
> > > Reminds me: should/can __UNCONST() be revisited w.r.t. the thread below?
> > >
> > > http://lists.freebsd.org/pipermail/freebsd-arch/2013-May/014371.html
> >
> >How/why? Yes, it's unsafe. That's the *point*.
>
> Well, there
In article <20130601232927.ga19...@netbsd.org>,
David Holland wrote:
>On Fri, May 31, 2013 at 12:26:53PM +0300, Jukka Ruohonen wrote:
> > > Module Name: xsrc
> > > Committed By: mrg
> > > Date: Fri May 31 06:46:39 UTC 2013
> > >
> > > Modified Files:
> > > xsrc/external/mi
On Fri, May 31, 2013 at 12:26:53PM +0300, Jukka Ruohonen wrote:
> > Module Name: xsrc
> > Committed By: mrg
> > Date: Fri May 31 06:46:39 UTC 2013
> >
> > Modified Files:
> >xsrc/external/mit/xauth/dist: process.c
> >
> > Log Message:
> > apply __UNCONST() if
In article <20130531092653.GA24785@marx.bitnet>,
Jukka Ruohonen wrote:
>On Fri, May 31, 2013 at 06:46:39AM +, matthew green wrote:
>> Module Name: xsrc
>> Committed By:mrg
>> Date:Fri May 31 06:46:39 UTC 2013
>>
>> Modified Files:
>> xsrc/external/mit/xauth/dist:
On Fri, May 31, 2013 at 06:46:39AM +, matthew green wrote:
> Module Name: xsrc
> Committed By: mrg
> Date: Fri May 31 06:46:39 UTC 2013
>
> Modified Files:
> xsrc/external/mit/xauth/dist: process.c
>
> Log Message:
> apply __UNCONST() if it exists.
Reminds me: should/can __UNC