public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "icksa1 at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/30487] New: Math implicit function in forall statement causes compiler error Date: Tue, 16 Jan 2007 20:33:00 -0000 [thread overview] Message-ID: <bug-30487-12850@http.gcc.gnu.org/bugzilla/> (raw) Hi: I noticed that whenever I use a math function (such as sqrt, cos, log) in a forall all statement that further uses of that function caused gfortran to say that the function has no implicit type. I've shown an example program below: program test implicit none integer :: i real :: a, c(5) = (/1.0,2.0,3.0,4.0,5.0/), d(5) a = sqrt(2.0) d(:) = 0.0 forall (i = 1:5, sqrt(c(i)) < 2.0) d(i) = i end forall end program test If I try to compile the above program I get the following error: In file test.f90:8 a = sqrt(2.0) 1 Error: Symbol 'sqrt' at (1) has no IMPLICIT type If I comment out the line "a = sqrt(2.0)", everything works fine. Also, if I don't use the sqrt test in the forall statement, everything works fine. If you substitute other mathematical functions for sqrt (such as log or cos) it fails to compile in a similar way. I tried this in the latest experimental build (downloaded from the gfortran wiki) and had similar problems. Thank You -- Summary: Math implicit function in forall statement causes compiler error Product: gcc Version: 4.1.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: icksa1 at gmail dot com 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=30487
next reply other threads:[~2007-01-16 20:33 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2007-01-16 20:33 icksa1 at gmail dot com [this message] 2007-01-16 21:30 ` [Bug fortran/30487] " burnus at gcc dot gnu dot org 2007-01-17 1:37 ` kargl at gcc dot gnu dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-30487-12850@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).