TIP: Click on subject to list as thread! ANSI
echo: c_echo
to: andrew clarke
from: Pascal Schmidt
date: 2004-04-26 13:29:40
subject: [C] typecasting

Hi andrew! :-)

 PS>> Your format specifier and cast do not match. You want:
 PS>>     printf("%u\n", (unsigned int) i);
 ac> Or just
 ac>   printf("%u\n", i);
 ac> The typecast is redundant.
Yes, you are right, even gcc with -Wall -W doesn't warn for it.

Ciao
Pascal

--- Msged/LNX 6.1.1
* Origin: Linux FAQ - http://www.tzi.de/~pharao90/faq/ (1:153/401.2)
SEEN-BY: 633/267 270
@PATH: 153/401 307 140/1 106/2000 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.