From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id D2FFA385E006; Thu, 26 Mar 2020 14:05:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D2FFA385E006 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1585231516; bh=dp5XPc8G4mX+JBifFUWynyoYgW2mrGX19R+umrOFBC0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=CHT8+oquTPETRHYbC7SJOCkPUaUTHKv3wx5R5WyXSFYj808FIzo4+MrK36mGt6g2+ tiv3Y3rWLp1svefpBK/dRSrTJn1XBF0R7Teu3YiIi++ro5PDQFqbN5SXieHrGLBJVJ EBxMxkd6aUQ5dMuIZOYxzXhE3K+6HMj3I7caAMKU= From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: =?UTF-8?B?W0J1ZyBjKysvOTQzMjZdIGcrKzogZXJyb3I6IHBhY2suaWk6IA==?= =?UTF-8?B?4oCYLWZjb21wYXJlLWRlYnVn4oCZIGZhaWx1cmUgKGxlbmd0aCk=?= Date: Thu, 26 Mar 2020 14:05:16 +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: 10.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 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, 26 Mar 2020 14:05:16 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D94326 --- Comment #4 from Jakub Jelinek --- --- gcc/cp/call.c.jj 2020-03-25 08:05:07.153731580 +0100 +++ gcc/cp/call.c 2020-03-26 15:03:42.432909693 +0100 @@ -333,11 +333,14 @@ set_flags_from_callee (tree call) && internal_fn_flags (CALL_EXPR_IFN (call)) & ECF_NOTHROW) nothrow =3D true; - if (!nothrow && at_function_scope_p () && cfun && cp_function_chain) - cp_function_chain->can_throw =3D 1; + if (cfun && cp_function_chain && !cp_unevaluated_operand) + { + if (!nothrow && at_function_scope_p ()) + cp_function_chain->can_throw =3D 1; - if (decl && TREE_THIS_VOLATILE (decl) && cfun && cp_function_chain) - current_function_returns_abnormally =3D 1; + if (decl && TREE_THIS_VOLATILE (decl)) + current_function_returns_abnormally =3D 1; + } TREE_NOTHROW (call) =3D nothrow; } seems to work, but not sure if that is what we want.=