From patchwork Fri Dec 22 02:29:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sandra Loosemore X-Patchwork-Id: 182508 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:2483:b0:fb:cd0c:d3e with SMTP id q3csp809298dyi; Thu, 21 Dec 2023 18:29:54 -0800 (PST) X-Google-Smtp-Source: AGHT+IHdBXRDJDpWaOWMBhlhq8O91np7I0MXqIidTtMZiY9gRAEa+hdt6j7nUSHqDgYjUtLVU9dt X-Received: by 2002:ac8:58ca:0:b0:425:994b:caf0 with SMTP id u10-20020ac858ca000000b00425994bcaf0mr960310qta.23.1703212194003; Thu, 21 Dec 2023 18:29:54 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1703212193; cv=pass; d=google.com; s=arc-20160816; b=cl6wBMhRpjHQR+fz3hU1NH+Lfde+7zNvhSGeucDmO3FmBzfEQKa/DGjbwVMfQfPJkV rV8ftiRNE94aZf3nZpiQQoFs0xAOliifrzPQ73NW7+HBdN3qilSomBNFR9fz44F9ZNdI GZJp3mfMk/aSLpWzLHYDKcklJL1Wx0GgMxerkQNzH8MwOM7SL2PyG9hFvW1HBbXGkAuk +H1LTRW2sJiZ399cvTamExwGAq9saOHK2eOULITdGwXEp0MBeZt2Izvqsod+Dl47Q8ce LtLVGk5LmAdiLqEaNMN+GRURe+Z3LOYMM2//vxRfTUxS4Ct3d+88irn1LcWDi51UExqO Yccg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:to:from:ironport-sdr :arc-filter:dmarc-filter:delivered-to; bh=dpI2pFp4g6KTZmQbisDqDmexLkLLF0v7Gx/un1oQkiQ=; fh=gk9A5O7Gbglvz1MjrRQ4hZ2i3c68kYkpOZJg1emXh+g=; b=Q2Pu16AQdkCAbmwFiidG7hHvmRkfbIhjLTI2ZL3xU2mj2d3JbtRWXC4QowMcTTfpAN x5MOizkZyVkZFP4f9lw6Uu9N7FZ53BGI6raP6F1G0yaL4cWJ9fHH24vRDHsGsh+I7pPW HMHhcFSHr0KtiO5/pNWe0XglBdK1ptmKuZCG6WNvRTb/kWvhA+MhJbyIFgxV9A2lXHAN IQWHywvRxgjlrYUDtjJipZ9VGWVc6KnueDl1hR1waxvswhXft+9CRYBmBUDFg74q76S+ hi52F8vCXgsWVDxCRRLrRHYlBxXRtu9AXKKSdnqcgk14nXv46xHp+E3PJZKLX8q69SbK 0HTg== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id t3-20020a05622a148300b00417dd658ebesi3419961qtx.686.2023.12.21.18.29.53 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Dec 2023 18:29:53 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 169EA385800B for ; Fri, 22 Dec 2023 02:29:53 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from esa2.mentor.iphmx.com (esa2.mentor.iphmx.com [68.232.141.98]) by sourceware.org (Postfix) with ESMTPS id 4AFA63858D33 for ; Fri, 22 Dec 2023 02:29:28 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4AFA63858D33 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4AFA63858D33 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=68.232.141.98 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1703212169; cv=none; b=FcsBaNaluntCvvuoMWNbVJL2eKzgV0xn8Y+5eWpvzzHWAXNuI9NLYHRtm9+O9MC7SUTCGjPr8X+17pWe4FRuhJALzwwRDxWmRZllZATd0FId1lwL5tzwtxiVlG8uoARzVPqJ15PP+jYar8Veo66l9wdgYWWzj71+l0XjObTjOMw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1703212169; c=relaxed/simple; bh=cqomoKoMXv92gzRdT2Ohk+ep2afdd47cM+stUiMG9iI=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=HTovyDF0q0z4v+2l+h7aZatsMP2Z3Hh8pV2iaHlhAtu9IrpDU+ZziVTIS3hC5A9y0xgyGcFanA3ayg8j6E4T3pcH9QO6ThYQ6MHkhCg8Y9dLa4tLyN4a3Ocu3oG3QriLwfqSLvVnLwOQ3vFonKIQd0pzblO1YPOJlLVeHgiOyVs= ARC-Authentication-Results: i=1; server2.sourceware.org X-CSE-ConnectionGUID: ity6VhbvT6KyRWk9ixERsw== X-CSE-MsgGUID: rxOfEne9R5ePY/aWyB//Rw== X-IronPort-AV: E=Sophos;i="6.04,294,1695715200"; d="scan'208";a="29053111" Received: from orw-gwy-02-in.mentorg.com ([192.94.38.167]) by esa2.mentor.iphmx.com with ESMTP; 21 Dec 2023 18:29:27 -0800 IronPort-SDR: yvSSv8bHupkgc0N8qrUk1xd1niYrd7QrCXvU9QsyK8lwuz4C3jLa95TJgU4fLpVk0nJ+KwPRrl zoVp22JFwqG5qjwySIOcFL4cDWLh/K3mlLB3ZKMfdjkhFHtC/weVjPCv9LhrD/Og71GyzfwsQG j8eE1hMjLfAr19cWxJscCvMY6HTjmjZncVZdwMEK4j+YoUyM2cysl7sywydLi9feFfPvv8yNZ8 q1/jCJQoQ47bBKf0pRNoE+0Il1sEwNM1gtbqsUvCtu3mWr1b1JpDscWM69q9lnd9956S4613BU Yfs= From: Sandra Loosemore To: Subject: [Committed, obvious] Testsuite: Fix failures in g++.dg/analyzer/placement-new-size.C Date: Thu, 21 Dec 2023 19:29:01 -0700 Message-ID: <20231222022901.1253705-1-sandra@codesourcery.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-ClientProxiedBy: svr-orw-mbx-14.mgc.mentorg.com (147.34.90.214) To svr-orw-mbx-11.mgc.mentorg.com (147.34.90.211) X-Spam-Status: No, score=-10.0 required=5.0 tests=BAYES_00, GIT_PATCH_0, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1785947429408467766 X-GMAIL-MSGID: 1785947429408467766 This testcase was failing on uses of int8_t, int64_t, etc without including . gcc/testsuite/ChangeLog * g++.dg/analyzer/placement-new-size.C: Include . Also add missing newline to end of file. --- gcc/testsuite/g++.dg/analyzer/placement-new-size.C | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/g++.dg/analyzer/placement-new-size.C b/gcc/testsuite/g++.dg/analyzer/placement-new-size.C index 75a5a159282..f6c7bd4de5f 100644 --- a/gcc/testsuite/g++.dg/analyzer/placement-new-size.C +++ b/gcc/testsuite/g++.dg/analyzer/placement-new-size.C @@ -2,6 +2,7 @@ #include #include +#include extern int get_buf_size (); @@ -34,4 +35,4 @@ void test_binop () int32_t *i = ::new (p + 1) int32_t; /* { dg-warning "heap-based buffer overflow" } */ *i = 42; /* { dg-warning "heap-based buffer overflow" } */ free (p); -} \ No newline at end of file +}