* How to warn about possibly truncated values?
@ 1999-11-17 17:59 Trevor Yann
1999-11-30 23:28 ` Trevor Yann
0 siblings, 1 reply; 2+ messages in thread
From: Trevor Yann @ 1999-11-17 17:59 UTC (permalink / raw)
To: help-gcc
In the following code it is possible that the assignment of x will
result in the value being truncated.
Is there a way to get gcc to warn about this code?
extern unsigned long g(void);
unsigned short f(void)
{
unsigned short x = g();
return x;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* How to warn about possibly truncated values?
1999-11-17 17:59 How to warn about possibly truncated values? Trevor Yann
@ 1999-11-30 23:28 ` Trevor Yann
0 siblings, 0 replies; 2+ messages in thread
From: Trevor Yann @ 1999-11-30 23:28 UTC (permalink / raw)
To: help-gcc
In the following code it is possible that the assignment of x will
result in the value being truncated.
Is there a way to get gcc to warn about this code?
extern unsigned long g(void);
unsigned short f(void)
{
unsigned short x = g();
return x;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1999-11-30 23:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-11-17 17:59 How to warn about possibly truncated values? Trevor Yann
1999-11-30 23:28 ` Trevor Yann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).