public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/18111] New: [gfortran] spurious warnings with -W -Wall
@ 2004-10-22 14:04 martin at mpa-garching dot mpg dot de
  2004-10-22 14:09 ` [Bug fortran/18111] spurious warnings with -W -Wunused pinskia at gcc dot gnu dot org
                   ` (9 more replies)
  0 siblings, 10 replies; 25+ messages in thread
From: martin at mpa-garching dot mpg dot de @ 2004-10-22 14:04 UTC (permalink / raw)
  To: gcc-bugs

When compiling the code below, gfortran emits warnings about unused
variables which are not defined by the user:

module misc_utils
implicit none

interface toString
  module procedure toString_i, toString_sp
end interface

contains

function toString_i (num)
  integer, intent(in) :: num
  character (len=30) :: toString_i

  write(toString_i,*) num
  toString_i = trim(adjustl(toString_i))
end function

function toString_sp (num)
  real, intent(in) :: num
  character (len=30) :: toString_sp

  write(toString_sp,*) num
  toString_sp = trim(adjustl(toString_sp))
end function

end module misc_utils


~/tmp>gfortran -Wunused -W -v -c misc_utils.f90
Reading specs from /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.0.0/specs
Configured with: /scratch/gcc/configure --quiet
--prefix=/afs/mpa/data/martin/ugcc --enable-languages=c++,f95
--with-gmp=/afs/mpa/data/martin/mygmp
Thread model: posix
gcc version 4.0.0 20041021 (experimental)
 /afs/mpa/data/martin/ugcc/libexec/gcc/i686-pc-linux-gnu/4.0.0/f951
misc_utils.f90 -quiet -dumpbase misc_utils.f90 -mtune=pentiumpro -auxbase
misc_utils -Wunused -W -version -o /tmp/ccSekDLb.s
GNU F95 version 4.0.0 20041021 (experimental) (i686-pc-linux-gnu)
        compiled by GNU C version 4.0.0 20041021 (experimental).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
misc_utils.f90:5: warning: unused parameter '.__result'
misc_utils.f90:5: warning: unused parameter '.__result'


Interestingly, the warnings are issued for line 5, which only contains
the interface description.

-- 
           Summary: [gfortran] spurious warnings with -W -Wall
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: martin at mpa-garching dot mpg dot de
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2006-08-21 20:13 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-18111-2736@http.gcc.gnu.org/bugzilla/>
2005-11-20 12:10 ` [Bug fortran/18111] spurious warnings with -W -Wunused martin at mpa-garching dot mpg dot de
2006-06-06 10:11 ` martin at mpa-garching dot mpg dot de
2006-06-06 10:14 ` martin at mpa-garching dot mpg dot de
2006-08-16 12:50 ` pault at gcc dot gnu dot org
2006-08-16 12:54 ` pault at gcc dot gnu dot org
2006-08-16 13:04 ` jakub at gcc dot gnu dot org
2006-08-16 21:58 ` paulthomas2 at wanadoo dot fr
2006-08-18  5:15 ` patchapp at dberlin dot org
2006-08-20  5:47 ` pault at gcc dot gnu dot org
2006-08-20  8:21 ` pault at gcc dot gnu dot org
2006-08-20 18:10 ` pault at gcc dot gnu dot org
2006-08-21 11:58 ` martin at mpa-garching dot mpg dot de
2006-08-21 13:32 ` paulthomas2 at wanadoo dot fr
2006-08-21 16:59 ` martin at mpa-garching dot mpg dot de
2006-08-21 20:13 ` paulthomas2 at wanadoo dot fr
2004-10-22 14:04 [Bug fortran/18111] New: [gfortran] spurious warnings with -W -Wall martin at mpa-garching dot mpg dot de
2004-10-22 14:09 ` [Bug fortran/18111] spurious warnings with -W -Wunused pinskia at gcc dot gnu dot org
2004-10-23 19:41 ` tobi at gcc dot gnu dot org
2004-10-26 11:15 ` martin at mpa-garching dot mpg dot de
2004-10-26 11:23 ` martin at mpa-garching dot mpg dot de
2004-10-26 17:32 ` tobi at gcc dot gnu dot org
2004-11-05  8:31 ` martin at mpa-garching dot mpg dot de
2004-11-05 11:20 ` Tobias dot Schlueter at physik dot uni-muenchen dot de
2004-11-05 19:52 ` cvs-commit at gcc dot gnu dot org
2004-11-05 20:03 ` tobi at gcc dot gnu dot org
2005-01-09  4:46 ` giovannibajo at libero dot it

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).