va_list的 [英] va_list
问题描述
我们可以将va_list初始化为NULL吗?
ie。 va_list = NULL
问候
Hi,
Can we intialize va_list to NULL?
ie. va_list = NULL
Regards
推荐答案
ramu< ra ***** *@gmail.comwrites:
ramu <ra******@gmail.comwrites:
我们可以将va_list初始化为NULL吗?
ie。 va_list = NULL
Can we intialize va_list to NULL?
ie. va_list = NULL
可能不是。 va_list是适合持有的对象类型
宏所需的信息va_start,va_arg,va_end和
va_copy;它不太可能是指针类型。
你想要完成什么?
-
Keith Thompson(The_Other_Keith) ks***@mib.org < http://www.ghoti.net/~kst> ;
圣地亚哥超级计算机中心< *< http://users.sdsc.edu/~kst>
我们必须做点什么。这是事情。因此,我们必须这样做。
- Antony Jay和Jonathan Lynn,是部长
Probably not. va_list is "an object type suitable for holding
information needed by the macros va_start, va_arg, va_end, and
va_copy"; it''s unlikely to be a pointer type.
What are you trying to accomplish?
--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
10月11日星期四2007 12:37:07 -0700,Keith Thompson写道:
On Thu, 11 Oct 2007 12:37:07 -0700, Keith Thompson wrote:
ramu< ra ****** @ gmail.comwrites:
ramu <ra******@gmail.comwrites:
>我们可以将va_list初始化为NULL吗?
ie。 va_list = NULL
> Can we intialize va_list to NULL?
ie. va_list = NULL
可能不是。 va_list是一个对象类型,适合于持有
所需的宏信息va_start,va_arg,va_end和va_copy" ;;
它不太可能是指针类型。
Probably not. va_list is "an object type suitable for holding
information needed by the macros va_start, va_arg, va_end, and va_copy";
it''s unlikely to be a pointer type.
我有一个实现,其中va_list是char *的typedef,并且知道
,其中它是typedef for void * 。此外,允许实现
将NULL定义为0,这是所有标量类型的有效初始化器。我
不会说我们可以可能不要将va_list初始化为NULL,只是
即使在允许
的系统上它也不是便携式的,也是个坏主意。
I have one implementation where va_list is a typedef for char *, and know
of one where it''s a typedef for void *. Also, implementations are allowed
to define NULL as 0, which is a valid initialiser for all scalar types. I
wouldn''t say we can "probably" not initialise a va_list to NULL, just
that it''s not portable and a bad idea even on the systems that do allow
it.
10月11日下午3:37,Keith Thompson< ks ... @ mib.orgwrote:
On Oct 11, 3:37 pm, Keith Thompson <ks...@mib.orgwrote:
ramu< ramu .... @ gmail.comwrites:
ramu <ramu....@gmail.comwrites:
我们可以将va_list初始化为NULL吗?
ie。 va_list = NULL
Can we intialize va_list to NULL?
ie. va_list = NULL
可能不是。 va_list是适合持有的对象类型
宏所需的信息va_start,va_arg,va_end和
va_copy;它不太可能是指针类型。
你想要完成什么?
-
Keith Thompson(The_Other_Keith)ks ... @ mib.org< http://www.ghoti.net/~kst>
圣地亚哥超级计算机中心< *< http:/ /users.sdsc.edu/~kst>
我们必须做点什么。这是事情。因此,我们必须这样做。
- Antony Jay和Jonathan Lynn,Yes Miniss
Probably not. va_list is "an object type suitable for holding
information needed by the macros va_start, va_arg, va_end, and
va_copy"; it''s unlikely to be a pointer type.
What are you trying to accomplish?
--
Keith Thompson (The_Other_Keith) ks...@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Miniss
对不起。我的意思是va_list ap = NULL;
not va_list = NULL;
Sorry. I meant va_list ap=NULL;
Not va_list = NULL;
这篇关于va_list的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!