From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24404 invoked by alias); 8 Jan 2006 21:32:57 -0000 Received: (qmail 24380 invoked by uid 48); 8 Jan 2006 21:32:55 -0000 Date: Sun, 08 Jan 2006 21:32:00 -0000 Message-ID: <20060108213255.24379.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/18540] Jumping into blocks gives error rather than warning In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "steven at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-01/txt/msg00758.txt.bz2 List-Id: ------- Comment #6 from steven at gcc dot gnu dot org 2006-01-08 21:32 ------- (From update of attachment 10595) Index: resolve.c =================================================================== --- resolve.c (revision 109449) +++ resolve.c (working copy) @@ -3579,9 +3579,12 @@ resolve_branch (gfc_st_label * label, gf if (found == NULL) { - /* still nothing, so illegal. */ - gfc_error_now ("Label at %L is not in the same block as the " - "GOTO statement at %L", &lp->where, &code->loc); + /* Still nothing, so strictly illegal. However, this kind of + what is now considered gross coding style was common in the + past. So allow it for legacy code. */ + gfc_notify_std (GFC_STD_LEGACY, + "Label at %L is not in the same block as the " + "GOTO statement at %L", &lp->where, &code->loc); return; } -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18540