From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id A78F73856DE7; Wed, 26 Oct 2022 04:28:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A78F73856DE7 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1666758523; bh=r9hxBmcRE7Vnc6zywZFUQWxgPrrmuk0vTv6cMA8oKkc=; h=From:To:Subject:Date:In-Reply-To:References:From; b=a9pL14VVi8nO/d/SwRvNd2rTW1hxLzho1ItpyMSNPe58WgHLHJHWjKFRu08Xzhs4g AUt7GuNimo8rSFWzOnOB3SWO7OcEiIWOTGSN7rTcKI25jaKvpdJQXIc2M1Pc+Z57lj 3Qq+Lfk9AfwhkHl8Q8UMvDdCHvJjvujjnIis/qes= From: "jirislaby at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/107405] enums can be wrongly long in gcc-13 (in gnu99) Date: Wed, 26 Oct 2022 04:28:43 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 13.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jirislaby at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: 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=3D107405 --- Comment #1 from Jiri Slaby --- (In reply to Jiri Slaby from comment #0) > Reduced testcase: > #include > enum { A =3D 0xffffffff, B =3D 1 << 31, }; > int main() { printf("%lx %x %zu\n", A, B, sizeof(B)); } It's also interesting to me, that A is long even with gcc-12...=