This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Pb on gcc : no warning on information lost.


Thank you for your response.
Yves Mocquard.

Le 14/04/2014 11:15, Marc Glisse a écrit :
(wrong list, you want gcc-help@gcc.gnu.org)

On Mon, 14 Apr 2014, Yves Mocquard wrote:

When I use gcc or g++ , I like when the compilator detects bug, with a an error of compliation or a warning.

see this code :

long long fct()
{
   return 0x123456789;
}
int main()
{
   int a = fct();
   cerr << a << endl;
}

when I compil with : g++ -Wall fic.cpp
I think that there should be a warning.

-Wconversion



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]