From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 5A9B63858C83; Wed, 1 Mar 2023 17:51:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 5A9B63858C83 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1677693089; bh=vBt6wYBYbBrl2dL2MoXFZBRdiYy+4GjNrOumtkfbaks=; h=From:To:Subject:Date:In-Reply-To:References:From; b=JXVKVEsmTTRID9uBYwgaaRyW0b1gR1FruhSoS2xoRh4ylPn2Dl6WyhA0vm39BGfKx QH8AdYjnIv1yQe54aeEGtOY9RqkAC/jYdYN3SM5wNQjzgnznjsL9UPLXk6tWgOAl+V jHPR9MxhrTMvGIDVJyuekjvgXzhvGExu6eoN/qjM= From: "cessenat at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/92639] Error: Integer too big for its kind at (1) Date: Wed, 01 Mar 2023 17:51:29 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cessenat at gmail dot com X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: INVALID X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D92639 --- Comment #2 from Olivier Cessenat --- integer(kind=3D4) valid range is -2147483648_4 to +2147483647_4. So I consider this is a gfortran bug. Moreover, if -2147483648_4 is considered out of range, why -2147483647_4 - 1_4 is not ? Constant elimination makes it evaluated to=20 -2147483648_4. I disagree with the term "there are no negative integers" [-2147483648_4 is equal to +2147483648_4] Other compilers, such as aocc, nvfortran, ifort, oneapi are OK with that Thanks=