From patchwork Mon Oct 25 11:54:45 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rainer Orth X-Patchwork-Id: 46598 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 1EEE5385843E for ; Mon, 25 Oct 2021 11:55:05 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp.CeBiTec.Uni-Bielefeld.DE (smtp.CeBiTec.Uni-Bielefeld.DE [129.70.160.84]) by sourceware.org (Postfix) with ESMTPS id B12BE3858C27; Mon, 25 Oct 2021 11:54:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B12BE3858C27 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=CeBiTec.Uni-Bielefeld.DE Authentication-Results: sourceware.org; spf=none smtp.mailfrom=cebitec.uni-bielefeld.de Received: from localhost (localhost [127.0.0.1]) by smtp.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTP id 0557FB10B9; Mon, 25 Oct 2021 13:54:47 +0200 (CEST) X-Virus-Scanned: amavisd-new at CeBiTec.Uni-Bielefeld.DE Received: from smtp.CeBiTec.Uni-Bielefeld.DE ([127.0.0.1]) by localhost (smtp.cebitec.uni-bielefeld.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id WPFga8N7HTyr; Mon, 25 Oct 2021 13:54:45 +0200 (CEST) Received: from manam.CeBiTec.Uni-Bielefeld.DE (p50855d38.dip0.t-ipconnect.de [80.133.93.56]) (Authenticated sender: ro) by smtp.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTPSA id BDDEFB0DAC; Mon, 25 Oct 2021 13:54:45 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=CeBiTec.Uni-Bielefeld.DE; s=20200306; t=1635162885; bh=gOoOC8OVwr7SsaslazGopwel/TogcjGVZaW/z5zA13w=; h=From:To:Cc:Subject:Date:From; b=h4aQ4/6P12EIDpM2ZFig7GAUDkll+VsyvoaV0Dv9c1QPBkmLFpCIIn0U8xPgKiwXt SPTdSBCBaAFdvclyEMD7qp3Brj75ybGedesyL1VO2wNNzY1mh6RuN+TnY0yS4gpPbt 4kqTIjoMZHlyttVgN0A5P/pNFnN20WY/l+A4ZHEFl7KkOa/su7dbWFpUSXG/zKv8oD +tLZfMNKv41kBRWzCfBro20p7/tW+IWs5PlPQsKiNISSrKavTu8C0KeiNHNSYjogmY W9qkA/e2fiOtYYFfCESrMIGP/0GUfb2Cbk0mx+HMN1rsccovyy2Z9/jT4V0KSwsVEG y/PwTQD8V7xMw== From: Rainer Orth To: gcc-patches@gcc.gnu.org Subject: [PATCH] libstdc++: Fix 17_intro/names.cc on Solaris Date: Mon, 25 Oct 2021 13:54:45 +0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1.90 (usg-unix-v) MIME-Version: 1.0 X-Spam-Status: No, score=-3794.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, GIT_PATCH_0, KAM_SHORT, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: libstdc++@gcc.gnu.org Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" 17_intro/names.cc and experimental/names.cc currently FAIL on Solaris FAIL: 17_intro/names.cc (test for excess errors) FAIL: experimental/names.cc (test for excess errors) Excess errors: /usr/include/sys/timespec_util.h:22: error: expected ')' before ';' token /usr/include/stdlib.h:157: error: expected unqualified-id before '[' token /usr/include/stdlib.h:157: error: expected ')' before '[' token has extern int timespeccompare(const struct timespec *l, const struct timespec *r); while has typedef struct drand48_data { unsigned int _initialised; unsigned short int x[3]; unsigned short int a[3]; unsigned int c; unsigned short lastx[3]; } drand48_data; both of which are broken by defining r resp. x to ( in the testcase. Fixed by undoing the defines. Tested on i386-pc-solaris2.11, sparc-sun-solaris2.11, and x86_64-pc-linux-gnu. Ok for master? Rainer # HG changeset patch # Parent 46e494d20576c10260ec41a54607f36eb946dc2e libstdc++: Fix 17_intro/names.cc on Solaris diff --git a/libstdc++-v3/testsuite/17_intro/names.cc b/libstdc++-v3/testsuite/17_intro/names.cc --- a/libstdc++-v3/testsuite/17_intro/names.cc +++ b/libstdc++-v3/testsuite/17_intro/names.cc @@ -251,6 +251,10 @@ #undef p // See https://gcc.gnu.org/ml/libstdc++/2019-05/msg00175.html #undef ptr +// uses this as parameter +#undef r +// uses this as member of drand48_data +#undef x #endif #ifdef __VXWORKS__