public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/46846] New: Warning of AINT as actual argument ain't right
@ 2010-12-08  9:05 burnus at gcc dot gnu.org
  2010-12-08 19:32 ` [Bug fortran/46846] " burnus at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: burnus at gcc dot gnu.org @ 2010-12-08  9:05 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: Warning of AINT as actual argument ain't right
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Keywords: diagnostic, documentation, wrong-code
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: burnus@gcc.gnu.org


http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/8ac296b9404b3245

lnblnk is a GNU extension.
char, ichar, int, and len_trim are also rejected by other compilers.

Currently, gfortran prints the warning

  Warning: Interface mismatch in dummy procedure 'fun' at (1): '%s' has
           the wrong number of arguments

for the intrinsics aint, anint, index, len and nint.

"13.6 Specific names for standard intrinsic functions"
Speci\fc Name    Generic Name Argument    Type and Kind
AINT           AINT                     default real
ANINT          ANINT                    default real
INDEX          INDEX                    default character
LEN            LEN                      default character
NINT           NINT                     default real

The problem is that all those functions have an optional KIND= argument -
which, however, is not included in the specific functions (as backward
compatibility to Fortran 77). Thus, the warning is bogus - but another question
is whether this can lead to wrong code by not passing NULL as second argument.


I have not checked, but maybe the documentation should also be improved (cf.
James' posting to c.l.f)


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

* [Bug fortran/46846] Warning of AINT as actual argument ain't right
  2010-12-08  9:05 [Bug fortran/46846] New: Warning of AINT as actual argument ain't right burnus at gcc dot gnu.org
@ 2010-12-08 19:32 ` burnus at gcc dot gnu.org
  2010-12-08 19:47 ` burnus at gcc dot gnu.org
  2010-12-09  8:05 ` burnus at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: burnus at gcc dot gnu.org @ 2010-12-08 19:32 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> 2010-12-08 19:31:57 UTC ---
Cf. also
http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/8cdbfa22b5b1ab00


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

* [Bug fortran/46846] Warning of AINT as actual argument ain't right
  2010-12-08  9:05 [Bug fortran/46846] New: Warning of AINT as actual argument ain't right burnus at gcc dot gnu.org
  2010-12-08 19:32 ` [Bug fortran/46846] " burnus at gcc dot gnu.org
@ 2010-12-08 19:47 ` burnus at gcc dot gnu.org
  2010-12-09  8:05 ` burnus at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: burnus at gcc dot gnu.org @ 2010-12-08 19:47 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Tobias Burnus <burnus at gcc dot gnu.org> 2010-12-08 19:47:50 UTC ---
Cf. also for REAL:
http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/bc0e811575b758ab
-- The documentation seems to be OK, but an ICE is shown at the very end (in
gfc_typenode_for_spec).


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

* [Bug fortran/46846] Warning of AINT as actual argument ain't right
  2010-12-08  9:05 [Bug fortran/46846] New: Warning of AINT as actual argument ain't right burnus at gcc dot gnu.org
  2010-12-08 19:32 ` [Bug fortran/46846] " burnus at gcc dot gnu.org
  2010-12-08 19:47 ` burnus at gcc dot gnu.org
@ 2010-12-09  8:05 ` burnus at gcc dot gnu.org
  2 siblings, 0 replies; 4+ messages in thread
From: burnus at gcc dot gnu.org @ 2010-12-09  8:05 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Tobias Burnus <burnus at gcc dot gnu.org> 2010-12-09 08:05:31 UTC ---
Another post by James about REAL:
http://groups.google.com/group/comp.lang.fortran/browse_thread/thread/991e2a17662a3bde


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

end of thread, other threads:[~2010-12-09  8:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-08  9:05 [Bug fortran/46846] New: Warning of AINT as actual argument ain't right burnus at gcc dot gnu.org
2010-12-08 19:32 ` [Bug fortran/46846] " burnus at gcc dot gnu.org
2010-12-08 19:47 ` burnus at gcc dot gnu.org
2010-12-09  8:05 ` burnus at gcc dot gnu.org

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