From patchwork Tue Nov 7 09:20:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Marc_Poulhi=C3=A8s?= X-Patchwork-Id: 162339 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:aa0b:0:b0:403:3b70:6f57 with SMTP id k11csp112296vqo; Tue, 7 Nov 2023 01:22:57 -0800 (PST) X-Google-Smtp-Source: AGHT+IEF4EkKHvDdDoDBHycQ2Zt3Hee0iUbhRLEc2g09ReoSeBPAzigQo9ZzIJi5rMY5XcX64TY2 X-Received: by 2002:ac8:59c3:0:b0:41c:e02a:eba0 with SMTP id f3-20020ac859c3000000b0041ce02aeba0mr41068578qtf.17.1699348976915; Tue, 07 Nov 2023 01:22:56 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1699348976; cv=pass; d=google.com; s=arc-20160816; b=FzODKrqd4uVzw96SOFI87Eax5e7deb2TqxTkK/Jb2MyH1T3EkSnEWM35knt7QxJB9X 1nFvwfn6vyIbhVEbFWw+xo2qbxpxMyK6F7cJ+NqLGYCYmP0F8A0KD0swh6lCJSgO9QeL z/q047cRnHgaXqNA77skXYa/9VUsadXz/2tNvLL5FV7DQs97cjVzvaG0uBiH/N7j8cgi 2YonRf/KQqLpju6TgogB1FGPxeykhFyA6Vl5i2sEN4cl95TwNbaXZwsQ42tIQf6apaFv NviCFUe6zu6tbY3OSFp/1ARvQiRHAAd9bgafpKYZdXm2uhl2/g+y34K0Xb+MarkdIX1Z 1QoQ== 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=HvlgSNiqbOqiUk3zeAOr0oHUMSBJemmc2b5oxPOGBsk=; fh=/LGSvS9fKr8xUSOarN/hPHAOWzvFwgUy+6Y4FjnH2j4=; b=X30/np+SK/oisthHyS0tfrQWb4VkTE2nWi4tLziEMl/rvVmBJmV/5kBMovno4mVMwg 3RHR6nXFTrXd7e8/37Hop8otI8TBH/zz4npjznVMaZRd4bjfYXd2IteYiLIv50KTDl5o Y/9b3yTbpCNBDAGeEGr0ZNwsdLVZPVh2QbkM5btekWGtpxJVdJcpJdjvQed0wFCnemdX /8YHrKrn/62rIp4yddzqeOAM35yYtGePHYWa6EcEpLAJLma6GvrENvRhUznAHEigPzbK /lKCxvWiZBehcM8iX2iOs3dC0x6PuKAImKr3GIaycovbIFWGduPic6VebBjKIMO6UGF+ zoaA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@adacore.com header.s=google header.b=DKQgbMXY; 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=adacore.com Received: from server2.sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id e8-20020a05622a110800b0040362bf7530si7045123qty.413.2023.11.07.01.22.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Nov 2023 01:22:56 -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; dkim=pass header.i=@adacore.com header.s=google header.b=DKQgbMXY; 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=adacore.com Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 2E59B382A2F2 for ; Tue, 7 Nov 2023 09:22:02 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) by sourceware.org (Postfix) with ESMTPS id 4D58E38618EE for ; Tue, 7 Nov 2023 09:20:13 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4D58E38618EE Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4D58E38618EE Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::629 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699348815; cv=none; b=kGR3ryZMxJ1/Q5VexPp48cuVZGoJD9l9DBXKq+PRfHDi9aWIrEIGc9b2n3fV0Bt25wBs/VWdg/EVGj59PWVafaFFt5X8/VBCGy4/GUGWVmaLxduC9dAOL6oZIN2j3UtDGQB6lT7KLHaAa/HwRTL+Zt213IEA/n9ADaBdcycOEos= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699348815; c=relaxed/simple; bh=MkuPhB0Yy+JggvzDNqI9JEnqDyLeCJRfKIFV7trcEOw=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=i4TP5yRG6XIpX7BOmRE/R+XO1Vsdkrnm/4IavyS6pnv11K4//vYZc/gMjiyATsTItsnwjH0VlzAtomS2dtVNYAF8S8jwQ9gmWXEUWxwlVdvSSiC3Vt72XU17L0XwU291r8i+IvFXDPyJ0YyKdb2iyLkimc95sxeN/Rd8XzMtmVs= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-ej1-x629.google.com with SMTP id a640c23a62f3a-9c53e8b7cf4so809452766b.1 for ; Tue, 07 Nov 2023 01:20:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1699348812; x=1699953612; darn=gcc.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=HvlgSNiqbOqiUk3zeAOr0oHUMSBJemmc2b5oxPOGBsk=; b=DKQgbMXYVJPbWRVapf/Ivk67TptMKfjTj3O7Wcv+C6t2LKDTynDnC/edhLjm1g2YUZ e1wFucsZhFQcy5AeQvXwqSEax9Td2lMebX7lqXtlzrgTlbWUd19ebasjwus30oRa8EPT ErmHr/MuWTSpUlMrSoPsIdDasQ5IDdKPLe2BfRTh36PHKHK0Kcn3ibqdQZukoY8AP7VD 95Df0ScMWnZQptpBHBvwlyRte7+v2x1JqUN2+pCK8FzzjRDpmbr/SddvHvs4PRFmZAV+ 4Cz4ecKe7Vc+QZ9QFY31oAkmcAwWFSOSZ0cRFPnjZnYlYHsf7twHWT6njwKZsi7hq/ln lf3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1699348812; x=1699953612; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=HvlgSNiqbOqiUk3zeAOr0oHUMSBJemmc2b5oxPOGBsk=; b=rXSuMmque3T/KNGVZ3S/ELLzLw32tITu4iVqlU0N651jdhfcOSdeHGwsvg18aNUxIA lhii41dLsh88VlFB41NnzAOeg6HjsxB7HgJJCIw1cyFiD3Il1mutOubL5PXilPsM5EVl nBL/hGpvUJk1pDamRDinkMVw/e2jm6zV8BNteCq75LU/GjWv0xMqUVKh20LP2sISt7Zu tnAVApWPzASmv3T9jataTyq52rJLiafsmocCO8AWPLXwY878uisd99guzgAQbdm5s86m BZ4lxlhw3nx5202efXhol410YF1O9zt5Vfgb5lKGZpETz7Jz8FpEYZghzq3bhatrmS2N O2uw== X-Gm-Message-State: AOJu0YxHMn1MLalY4ovKIYCdCTSQBl3C9mtGJ43zb7zz5W7GaN7vMiot 61tIsqcuvVx2Z4kmd6XMhS4WyGXwEIvRJ2WAFxJutQ== X-Received: by 2002:a17:907:1c17:b0:9bf:889e:32a4 with SMTP id nc23-20020a1709071c1700b009bf889e32a4mr14994160ejc.54.1699348812053; Tue, 07 Nov 2023 01:20:12 -0800 (PST) Received: from localhost.localdomain ([2001:861:3382:1a90:dbc1:a1d1:2e58:4040]) by smtp.gmail.com with ESMTPSA id z11-20020a05600c0a0b00b00407460234f9sm15301404wmp.21.2023.11.07.01.20.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Nov 2023 01:20:11 -0800 (PST) From: =?utf-8?q?Marc_Poulhi=C3=A8s?= To: gcc-patches@gcc.gnu.org Cc: Ronan Desplanques Subject: [COMMITTED] ada: Fix documentation of -gnatwc Date: Tue, 7 Nov 2023 10:20:09 +0100 Message-ID: <20231107092009.3906170-1-poulhies@adacore.com> X-Mailer: git-send-email 2.42.0 MIME-Version: 1.0 X-Spam-Status: No, score=-13.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, 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: 1781896552905109040 X-GMAIL-MSGID: 1781896552905109040 From: Ronan Desplanques -gnatwc has been correctly emitting warnings for expressions outside of tests for a while, but its documentation in the user's guide had never been updated to reflect that. Also, the documentation used "conditional expressions" to designate boolean expressions, but "conditional expressions" has been defined by Ada 2012 to designate if expressions and case expressions. This patch fixes those issues. gcc/ada/ * doc/gnat_ugn/building_executable_programs_with_gnat.rst: Fix -gnatwc documentation. * gnat_ugn.texi: Regenerate. Tested on x86_64-pc-linux-gnu, committed on master. --- .../doc/gnat_ugn/building_executable_programs_with_gnat.rst | 4 ++-- gcc/ada/gnat_ugn.texi | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gcc/ada/doc/gnat_ugn/building_executable_programs_with_gnat.rst b/gcc/ada/doc/gnat_ugn/building_executable_programs_with_gnat.rst index a708ef4b995..21e277d5916 100644 --- a/gcc/ada/doc/gnat_ugn/building_executable_programs_with_gnat.rst +++ b/gcc/ada/doc/gnat_ugn/building_executable_programs_with_gnat.rst @@ -2942,8 +2942,8 @@ of the pragma in the :title:`GNAT_Reference_manual`). .. index:: Conditionals, constant - This switch activates warnings for conditional expressions used in - tests that are known to be True or False at compile time. The default + This switch activates warnings for boolean expressions that are known to + be True or False at compile time. The default is that such warnings are not generated. Note that this warning does not get issued for the use of boolean constants whose diff --git a/gcc/ada/gnat_ugn.texi b/gcc/ada/gnat_ugn.texi index 1d91f2c13fa..78f8849e379 100644 --- a/gcc/ada/gnat_ugn.texi +++ b/gcc/ada/gnat_ugn.texi @@ -11000,8 +11000,8 @@ of biased representation. @geindex Conditionals @geindex constant -This switch activates warnings for conditional expressions used in -tests that are known to be True or False at compile time. The default +This switch activates warnings for boolean expressions that are known to +be True or False at compile time. The default is that such warnings are not generated. Note that this warning does not get issued for the use of boolean constants whose