This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/14557] va_list is automatically taken address-of when passed as argument


------- Additional Comments From hueffner at informatik dot uni-tuebingen dot de  2004-03-13 13:28 -------
Subject: Re:  va_list is automatically taken address-of
 when passed as argument

"jsm at polyomino dot org dot uk" <gcc-bugzilla@gcc.gnu.org> writes:

> ------- Additional Comments From jsm at polyomino dot org dot uk  2004-03-13 13:22 -------
> There's nothing wrong with using va_list *, the only problem is when
> taking the address of a parameter to do so.
>
> With a variable
>
> va_list ap;
>
> you use &ap to take the address.
>
> With a parameter (subject to array-to-pointer adjustment)
>
>   va_list ap
>
> you use &ap if va_list is not an array type, but ap if it is an
> array type.

Ah, I see. Thanks.



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14557


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]