From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id F3FFA385DC35; Mon, 22 Jun 2020 09:46:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F3FFA385DC35 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1592819188; bh=mpK1wQj/u6MWS6rYyhlguM9K3sfeiBF4KbeT8iBxC5U=; h=From:To:Subject:Date:In-Reply-To:References:From; b=hOF1zAyhm2d/uvV1DFukQXIZ/kfDP78BcQSGAY8ZiLtst7Z45y8U/4SdCxSJTpRV0 hFmHr7qMLHDPF7ZkXgjXsHWs2+WnTGdjrpp8cJSkiqm71MAGbSEyn3oL7hgc0BQnrs s7ulBVM9bqqXN7P3hKkNqqn9uRvnhntbcNrzOVVo= From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/95807] GCC accepts "void value not ignored as it ought to be" in function template Date: Mon, 22 Jun 2020 09:46:27 +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: accepts-invalid X-Bugzilla-Severity: normal X-Bugzilla-Who: redi 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: 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: Mon, 22 Jun 2020 09:46:28 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D95807 --- Comment #3 from Jonathan Wakely --- (In reply to Haoxin Tu from comment #2) > (In reply to Andrew Pinski from comment #1) > > I think it is rejected at instanition time. >=20 > Hi, Andrew. Shouldn't it be rejected at compiling time? It could be, but that is not required by the C++ standard. > Is this case similar with bug.cc? Yes. The ill-formed template is not diagnosed unless you instantiate it. Th= at is allowed by the standard.=