This is the mail archive of the gcc-bugs@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]

[Bug bootstrap/45372] New: warning coverage.c assigns -1 to unsigned, suggest -1u


just a warning, not an error
bootstrapping from non-gcc


"/home/jay/src/gcc-4.5.1/gcc/coverage.c", line 174: warning: initializer does
not fit or is out of range: -1
"/home/jay/src/gcc-4.5.1/gcc/coverage.c", line 330: warning: initializer does
not fit or is out of range: -1


-bash-3.00$ uname -a
SunOS ssol 5.10 Generic_139555-08 sun4u sparc SUNW,Sun-Blade-100


 /home/jay/src/gcc-4.5.1/configure \
        -disable-shared \
        -target=sparc64-sun-solaris2.10 \
        -with-mpfr=/home/jay \
        -disable-nls \
        -prefix=/home/jay \
        -disable-bootstrap \
        -with-as=/usr/ccs/bin/as


read_counts_file (void)
...
gcov_unsigned_t checksum = -1;  # line 174


gcov_type *
get_coverage_counts
...
gcov_unsigned_t checksum = -1; # line 330


bootstrap from:

-bash-3.00$ cc -V
cc: Sun C 5.9 SunOS_sparc Patch 124867-01 2007/07/12
usage: cc [ options] files.  Use 'cc -flags' for details


-1u gives no warning.
nor does (unsigned)-1
nor does, I suspect, (gcov_unsigned_t)-1


-- 
           Summary: warning coverage.c assigns -1 to unsigned, suggest -1u
           Product: gcc
           Version: 4.5.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: bootstrap
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jay dot krell at cornell dot edu


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


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