Message ID | 20231114191309.3709363-1-dmalcolm@redhat.com |
---|---|
State | Accepted |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:6358:a59:b0:164:83eb:24d7 with SMTP id 25csp2144199rwb; Tue, 14 Nov 2023 11:13:42 -0800 (PST) X-Google-Smtp-Source: AGHT+IH00T30xg8fmhDcUQC5A6i1vEyQi91FX1YbEMJB/NhB4rfsdjjxmXiY/a0/S5T+zl2wwmr0 X-Received: by 2002:a05:6214:519d:b0:66d:9f09:b69c with SMTP id kl29-20020a056214519d00b0066d9f09b69cmr3972026qvb.29.1699989222244; Tue, 14 Nov 2023 11:13:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1699989222; cv=pass; d=google.com; s=arc-20160816; b=bH8inSvDkR4/ZXB3ekFQMsS4KJJwlkCpfVLZfgh1j6ErcEtL5ZVoRzq+T39JITMQQb xVQjP6skY8og+HXu5PwKh/1Icu4lqr8oHSp55+yaKmQ/l++dlIYcT0AMDGmc8wHfycPm pJS0b3UId1/qIo3ILWTNWCY2LHoyMd460IRyqoLv7t8WIJ6Z6fcI9OmkqW0FnNP1L/k9 HbPWiV8BQhLSaCwfhSruCGlswvjD8f3gGR/xx39db4++soqeomZpprb2dZatTW3kd+ph W47lidCKCgvsv/svvN10UPYaRJS6QmTRnUCsMGMGLqfCvFdIEF82XawSrnZtKrI3tljg vhMQ== 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:cc:to:from:dkim-signature :arc-filter:dmarc-filter:delivered-to; bh=jf3QqeiL5T9gh8/2D+4NHh13kffUlYi4UDFLO9xjXAI=; fh=NXemEfxTRbZtBxUkxR2ehQUaYlcDfMdzPkO8MChVQE4=; b=u7SL3afO1ZSlDyoOcYtDMZ2qsyHXbhwXPuMCycBhcqjwLTSv3LV6dj0UmBbVVWrsta /J4E3wk+XwkrCDe2Qf43fmx6djppRJ26LQV50CP5LfgVNvFBNZYSovD6QfZp+GPldajb /rTVITqRaRXMqPAY9lGaLI0XZZ1lkdzWvg3FJh8q4vayAZjem6IUq7aF501T6e0hZwcc 9ZBtTZGDoVBGKhd7HbWrccAE/xvz0Lxv6pHXntxqVID1l44KhCq4gYZb3tr2dqh9g8Yo uNamerW8Xys7jGXk5wVn97L+bxqZdPvN/lTqKRrqOCZgalg9u1cFNujj/6h+TN9rrQCK 51zg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=EUWz8rs1; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from server2.sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id e18-20020ad44432000000b0066cf6a75891si7296693qvt.601.2023.11.14.11.13.42 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Nov 2023 11:13:42 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=EUWz8rs1; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id A8821385840F for <ouuuleilei@gmail.com>; Tue, 14 Nov 2023 19:13:40 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 532D53858C20 for <gcc-patches@gcc.gnu.org>; Tue, 14 Nov 2023 19:13:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 532D53858C20 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 532D53858C20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699989193; cv=none; b=NBh6MskGTAy/GGb6rO+6dm+G1okXgXnTCmEgzX5lt03HcvoG7PHjPZz5T7ER3DjcdOzFiYkrlPcErrYIVUu9EzLSV9fyrQQLsHsOJ/OoEaoBzlT4QkYNLLfbhyEuAvLVm1tuhbWQwaMWhWLUoOt5PAcOm8rI/9MVXTQWwhHkuVU= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699989193; c=relaxed/simple; bh=EHfYNbIG3jIHfb4+uCU+MuK1ySkFBSvXDLnqkYcqRAY=; h=DKIM-Signature:From:To:Subject:Date:Message-Id:MIME-Version; b=Q+U0O5GWiSwCzwVanefkcbnuUtthMVoHNDezSgPRBRErJoXYf2J5bxMTLo355eomaVOCdu5hNWedI4SM6II9aufVvI7Uqh3R/4h0mT3Ni3FGz1JcCAjpscOpLQtAgdXvgV+auatvyMgntHhQFsBSdjo43CEmUAxbOdxSRuTlxcs= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1699989192; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jf3QqeiL5T9gh8/2D+4NHh13kffUlYi4UDFLO9xjXAI=; b=EUWz8rs1Ib+p+yvuCzoaDqwpQavoS0B0sufk64c1B9lMVDdvkXndm/LtDyhNcsvhquCTAn Gch342E5bYfR3mJeWM2y3qxB89wlXmjoAeX13rg+dINrvRkQLAE0rQ3qZ2yj2mh+LN6M9Y lgsGP5/cxvwHzySbHa9nTM5aLrDWf8I= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-526-0KdJbWpNN1-4ElTXOsnQIw-1; Tue, 14 Nov 2023 14:13:10 -0500 X-MC-Unique: 0KdJbWpNN1-4ElTXOsnQIw-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 817C5811E7D for <gcc-patches@gcc.gnu.org>; Tue, 14 Nov 2023 19:13:10 +0000 (UTC) Received: from t14s.localdomain.com (unknown [10.22.10.115]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5D156502C; Tue, 14 Nov 2023 19:13:10 +0000 (UTC) From: David Malcolm <dmalcolm@redhat.com> To: gcc-patches@gcc.gnu.org Cc: David Malcolm <dmalcolm@redhat.com> Subject: [pushed] diagnostics: convert diagnostic_ready_p to an inline function Date: Tue, 14 Nov 2023 14:13:09 -0500 Message-Id: <20231114191309.3709363-1-dmalcolm@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-11.4 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_NONE, 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 <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782567898440703575 X-GMAIL-MSGID: 1782567898440703575 |
Series |
[pushed] diagnostics: convert diagnostic_ready_p to an inline function
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | success | Github commit url |
Commit Message
David Malcolm
Nov. 14, 2023, 7:13 p.m. UTC
No functional change intended. Successfully bootstrapped & regrtested on x86_64-pc-linux-gnu. Pushed to trunk as r14-5457-gd0bfd6ba3ba77f. gcc/ChangeLog: * diagnostic.h (diagnostic_ready_p): Convert from macro to inline function. --- gcc/diagnostic.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/gcc/diagnostic.h b/gcc/diagnostic.h index 7ae7cebf02ed..2489855ae4a4 100644 --- a/gcc/diagnostic.h +++ b/gcc/diagnostic.h @@ -764,7 +764,11 @@ extern diagnostic_context *global_dc; /* Returns whether the diagnostic framework has been intialized already and is ready for use. */ -#define diagnostic_ready_p() (global_dc->printer != NULL) +inline bool +diagnostic_ready_p () +{ + return global_dc->printer != nullptr; +} /* The number of errors that have been issued so far. Ideally, these would take a diagnostic_context as an argument. */