public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "fruitclover at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/104812] New: Construct-name with same variable name in scope Date: Mon, 07 Mar 2022 04:47:49 +0000 [thread overview] Message-ID: <bug-104812-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104812 Bug ID: 104812 Summary: Construct-name with same variable name in scope Product: gcc Version: 11.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: fruitclover at gmail dot com Target Milestone: --- Is this expected behavior for s1 to disallow construct-name with the same name as declared variable? $ cat -n test.f90 1 subroutine s1 2 logical :: x 3 x: if (x) then 4 end if x 5 end 6 7 subroutine s2 8 logical :: x 9 x: block 10 end block x 11 end $ gfortran test.f90 -fsyntax-only -Wall -Wextra test.f90:3:11: 3 | x: if (x) then | 1 Error: Symbol at (1) is not appropriate for an expression test.f90:4:5: 4 | end if x | 1 Error: Expecting END SUBROUTINE statement at (1)
next reply other threads:[~2022-03-07 4:47 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-03-07 4:47 fruitclover at gmail dot com [this message] 2022-03-07 15:22 ` [Bug fortran/104812] " kargl at gcc dot gnu.org 2022-03-10 11:27 ` fruitclover at gmail dot com 2022-03-10 14:57 ` sgk at troutmask dot apl.washington.edu 2022-04-05 15:25 ` fruitclover at gmail dot com 2022-04-05 16:31 ` kargl at gcc dot gnu.org 2022-04-05 17:37 ` fruitclover at gmail dot com
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-104812-4@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).