From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7ED5F389366C; Wed, 17 Jun 2020 23:49:42 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7ED5F389366C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1592437782; bh=3ZWnah0a4mOJxUzEm+MHI6ttGpVcZSZIip5tsytvY+0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=ECsD74YfB4Y87A7VRebQ0Pt5iWKmtmjBxZEowB2e5hcmRSNNsqg/Hf4nQUzdJEVwL MZGy4zCisYww9bxPgMW4S/g1NASCcPpMhx+Nav4acRYAGZ8Q0z7nqG7SxNySFJ+lPx 1RwdJTvR17brlzP+QP9PbP0SefcC5vYtpIPFoC4U= From: "mpolacek at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/95725] Confusing error diagnostic in an invalid template Date: Wed, 17 Jun 2020 23:49:42 +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: 11.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mpolacek at gcc dot gnu.org 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: cc 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Jun 2020 23:49:42 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95725 Marek Polacek changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mpolacek at gcc dot gnu.org --- Comment #4 from Marek Polacek --- (In reply to Martin Sebor from comment #3) > The diagnostic is usually for false positive/negative warnings or wrong > information in diagnostic messages. It's not normally used for internal > compiler errors. But I don't see an ICE on trunk with this test case, ju= st > errors (so diagnostic would seem appropriate). At the same time, the lat= est > GCC output seems reasonable. Clang prints something similar: >=20 > pr95725.C:1:20: error: expected expression > template ^ > pr95725.C:1:22: error: expected expression > template ^ > pr95725.C:1:22: error: expected ',' or '>' in template-parameter-list > pr95725.C:1:22: warning: declaration does not declare anything > [-Wmissing-declarations] > 1 warning and 3 errors generated. >=20 > I'm not sure there's a lot to improve here. Agreed. As I said in bug 95723, I'm on the verge of closing these reports = as WONFIX or INVALID or something similar.=