From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 82FFB393C89A; Thu, 18 Jun 2020 01:51:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 82FFB393C89A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1592445078; bh=BGt9EKBNLnyJ6cPZhWd8RpDhO4kioB8gx5hq4VCtZL0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=tn3jqvfChD7vRM6HrhYc9ounL77fh0H3mvGZwYilYrZqLUIvliC+Ljk7HVCRxg1cZ 2mlcdS+itTJHczuN9KNDvAlH1Gldl3zHPkaF69W2ITiVMKWWisJwm+hqoji4ZLDKMa 9mmobSn7E8/ThhJsN9FPva4Y9BRBv61rrewXS65A= From: "haoxintu at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/95725] Confusing error diagnostic in an invalid template Date: Thu, 18 Jun 2020 01:51:18 +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: haoxintu 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 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: Thu, 18 Jun 2020 01:51:18 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95725 --- Comment #6 from Haoxin Tu --- Hi, there. I hold the view that the compiler should have good fault tolerance, which m= eans giving an input(even invalid), the compiler might emit appropriate error message diagnostics so that we can fix them into valid code according to the diagnostics.=20 I have tested in both GCC and Clang, the results show that GCC has lots of unrelated diagnostic messages than Clang.=20 In this report, GCC-trunk seems ok, but GCC-9 emits too many duplicated err= or messages. So I guess there might something not correct in FE. Finally, I am wondering if those cases are useful for the GCC community? If not, I will stop reporting similar test cases (invalid code but let GCC get confused while parsing it). Thank you all!=