[Bug c++/33403] "warning: missing sentinel in function call" for 0 rather than NULL

2007-09-12 Thread pinskia at gcc dot gnu dot org


--- Comment #3 from pinskia at gcc dot gnu dot org  2007-09-12 09:18 ---
(In reply to comment #2)
> I don't know about "most likely." sizeof(int) == sizeof(void*) is still pretty
> common, so my guess would be that the warning is more often wrong than not.

Common on ILP32 targets but since this was reported for LP64 target anyways,
what is the difference.  Remember sizeof(int) might be equal to sizeof(void*)
on most targets but it does not have to.  In fact this warning is for
portability reasons (though in this case is also correctness).


-- 


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



[Bug c++/33403] "warning: missing sentinel in function call" for 0 rather than NULL

2007-09-11 Thread sebor at roguewave dot com


--- Comment #2 from sebor at roguewave dot com  2007-09-12 03:56 ---
(In reply to comment #1)
> This is not a bug, 0 will be pasted as the same size as an int which means it
> will most likely not be passed as the same size as a NULL pointer.

I don't know about "most likely." sizeof(int) == sizeof(void*) is still pretty
common, so my guess would be that the warning is more often wrong than not.


-- 


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



[Bug c++/33403] "warning: missing sentinel in function call" for 0 rather than NULL

2007-09-11 Thread pinskia at gcc dot gnu dot org


--- Comment #1 from pinskia at gcc dot gnu dot org  2007-09-12 00:27 ---
This is not a bug, 0 will be pasted as the same size as an int which means it
will most likely not be passed as the same size as a NULL pointer.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution||INVALID


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