From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5575 invoked by alias); 28 May 2006 11:12:46 -0000 Received: (qmail 5513 invoked by uid 48); 28 May 2006 11:12:38 -0000 Date: Sun, 28 May 2006 11:12:00 -0000 Subject: [Bug libfortran/27784] New: Comparison of strings with char(0) X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "tkoenig 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-05/txt/msg02808.txt.bz2 List-Id: $ cat string_null_compare_1.f program main character*3 str1, str2 call setval(str1, str2) if (str1 == str2) print *,'Should be unqual' end subroutine setval(str1, str2) character*3 str1, str2 str1 = 'a' // CHAR(0) // 'a' str2 = 'a' // CHAR(0) // 'c' end $ gfortran string_null_compare_1.f $ ./a.out Should be unqual $ g77 string_null_compare_1.f $ ./a.out $ -- Summary: Comparison of strings with char(0) Product: gcc Version: 4.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libfortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: tkoenig at gcc dot gnu dot org OtherBugsDependingO 19292 nThis: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27784