From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29966 invoked by alias); 10 Sep 2006 19:23:50 -0000 Received: (qmail 29940 invoked by uid 48); 10 Sep 2006 19:23:42 -0000 Date: Sun, 10 Sep 2006 19:23:00 -0000 Message-ID: <20060910192342.29939.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/27989] -fbounds-check should check for too small arrays on subroutine calls In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "tobias dot burnus at physik dot fu-berlin dot de" 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-09/txt/msg00810.txt.bz2 List-Id: ------- Comment #2 from tobias dot burnus at physik dot fu-berlin dot de 2006-09-10 19:23 ------- Maybe this should not be done with -fbounds-check, but put into a different option. (NAG uses not -C=array but -C=call for this.) The reason is that some programs (e.g. Exciting.sf.net) passes an array(n-1) to a subroutine foo(n,b) with "real :: b(n)" but only accesses the first n-1 elements. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27989