This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/52661] negative maxint for long long gives warning
- From: "jmichae3 at yahoo dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 22 Mar 2012 21:54:16 +0000
- Subject: [Bug c/52661] negative maxint for long long gives warning
- Auto-submitted: auto-generated
- References: <bug-52661-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52661
--- Comment #15 from Jim Michaels <jmichae3 at yahoo dot com> 2012-03-22 21:54:16 UTC ---
oops, made amistake there.
if (-1==sign && 9223372036854775808==mantissa) {
datum=mantissa*sign;
} else if (1==sign && 9223372036854775808==mantissa) {
datum=mantissa;
} else if (-1==sign && mantissa > 9223372036854775808) {
printf("error:....\n");
} else if (1==sign && mantissa > 9223372036854775808) {
printf("error:....\n");
} else {
datum=sign*mantissa;
}