[EMAIL PROTECTED] wrote:

> On 7/6/07, Ernie Wright <[EMAIL PROTECTED]> wrote:
> 
>> > (now someone will tell me the compiler is correct and casting "int
>> > *x[]" to "void **" is indeed wrong :-)
>>
>> This is question 4.9 in the C FAQ:
>>
>>     http://c-faq.com/ptrs/genericpp.html
> 
> 
> That's very interesting, thank you. Does that mean that (void **)
> ((void *) x) fixes the problem correctly? Or do you need a real
> intermediate variable?

That may depend on what you mean by "correctly."  :)

Someone smarter than I should be consulted, but I believe that the
intermediate cast works exactly as if a temp variable were involved.

Or, looking at "correctly" differently, it's OK to cast away the warning
on systems for which all pointers have the same representation.

See also

    http://groups.google.com/group/comp.lang.c/msg/42f0898e5500d015?hl=en

- Ernie                                  http://home.comcast.net/~erniew
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to