[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnu-arch-users] Re: posible issue on ia64 with va_args.
From: |
Miles Bader |
Subject: |
[Gnu-arch-users] Re: posible issue on ia64 with va_args. |
Date: |
Fri, 12 Mar 2004 17:01:04 -0500 |
User-agent: |
Mutt/1.3.28i |
On Fri, Mar 12, 2004 at 10:03:04AM +0100, Jan Hudec wrote:
> > Even when that relation holds, this particular case can screw you; for
> > it to `work', you need sizeof (int) == sizeof (whatever_ptr).
>
> Even than, the spec does not guarantee you are safe.
>
> The spec does not say anything about relation of pointer to integer. It
> implies, that (void *)0 == NULL and (int)NULL == 0, but does not say the
> memory representation is the same.
Of course, but I don't think that particular silliness happens in practice
anymore (though I suppose maybe there were a few wonky-ass computers back in
the day that had odd non-zero representations of a null pointer). There's
too much dependence on using bzero to initialize pointer-containing
structures these days for a non-zero null to fly, and there's no pressure for
that to change (whereas there _is_ pressure pushing integer/pointer size
differences).
[After all, at least according to C89, you can't even depend on a
two's-complement representation for integers! Did they change that in C99,
BTW? I vaguely recall that they did...]
-Miles
--
Would you like fries with that?
- [Gnu-arch-users] posible issue on ia64 with va_args., Robert Collins, 2004/03/10
- Re: [Gnu-arch-users] posible issue on ia64 with va_args., Tom Lord, 2004/03/11
- [Gnu-arch-users] Re: posible issue on ia64 with va_args., Miles Bader, 2004/03/11
- Re: [Gnu-arch-users] posible issue on ia64 with va_args., Andrew Suffield, 2004/03/11
- Re: [Gnu-arch-users] posible issue on ia64 with va_args., Jan Hudec, 2004/03/11
- [Gnu-arch-users] Re: posible issue on ia64 with va_args., Miles Bader, 2004/03/12
- [Gnu-arch-users] Re: posible issue on ia64 with va_args., Jan Hudec, 2004/03/12
- [Gnu-arch-users] Re: posible issue on ia64 with va_args.,
Miles Bader <=
- Re: [Gnu-arch-users] Re: posible issue on ia64 with va_args., Andrew Suffield, 2004/03/16
- [Gnu-arch-users] Re: posible issue on ia64 with va_args., Stefan Monnier, 2004/03/16
- Re: [Gnu-arch-users] Re: posible issue on ia64 with va_args., Andrew Suffield, 2004/03/18
- Re: [Gnu-arch-users] Re: posible issue on ia64 with va_args., Jan Hudec, 2004/03/18