From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id qaxNOhDzfmryQSUAWB0awg (envelope-from ) for ; Fri, 14 Aug 2026 06:50:56 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=V+aqhM/l; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=V+aqhM/l; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id E806C1E0A3; Fri, 14 Aug 2026 06:50:56 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-5.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=unavailable autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [IPv6:2620:52:6:3111::32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 5CE6D1E033 for ; Fri, 14 Aug 2026 06:50:56 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 148D94BA79A0 for ; Fri, 14 Aug 2026 10:50:55 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 148D94BA79A0 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=V+aqhM/l; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=V+aqhM/l Received: from AM0PR02CU008.outbound.protection.outlook.com (mail-westeuropeazlp170130006.outbound.protection.outlook.com [IPv6:2a01:111:f403:c201::6]) by sourceware.org (Postfix) with ESMTPS id F40CF4BA23E8 for ; Fri, 14 Aug 2026 10:50:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org F40CF4BA23E8 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=arm.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org F40CF4BA23E8 Authentication-Results: sourceware.org; arc=pass smtp.remote-ip=2a01:111:f403:c201::6 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1786704626; cv=pass; b=Rg7pSosez9QofHUGgScmf8YhI2ilxUCo5gJTudVoBEDE1hjOdTlsfWTpQ5iQ47ZVF4/STqL5PO4n/MjFAsASeVMnx2j7JYFZ2fSzrBwDqiJyTBq7Iv0oiJc5fsMQaPsAwyLFb+UI26Lnuu/GN8TKFu//JVNSqD9T6JwqqF0lKKQ= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1786704626; c=relaxed/simple; bh=SoTOoHgv4wG4yPBeI24POpyi9lKFQa4C3vBMhKAifho=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=Cis/sTpEXi/ZnDZ7dIT6IsfEeE6ykZbFJDtn+Kie+YnCzpwKPaujzbdPwllcdpJxVPLdC5fDo8PNuxX1G89AdbU9ih8F2XzP0rdvYMvYIhO6bpv+MxJfjjXQJwR+fX7OGI/qeYGt3zXVuXsWQswaJ21L3f5E0JCAEGWbOM9dEjg= ARC-Authentication-Results: i=3; sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=V+aqhM/l; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=V+aqhM/l DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F40CF4BA23E8 ARC-Seal: i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass; b=ornoMMqG9h0FQ8kuzYVMcoAeuC14QxNL7KnFx0a4PLwgY3H7z8ol9+vNqaVZuUw1utPJwXb6QGbV+BL4nRyhVqaldsslqykstActTtptTlbxkQTO7Zgxl61d/Z/F98RPvrLhsbFuVfAHIqKze4qETYbNvE9+dD0312cpealvQUiP2mWJJbx/NEOTvzJxfRZhS+cAwHDXepbydvopRFL699EhQRgdXEaBVDiJeRD9NI7hb0nMtI0Zx4sQEUcMQn7GaP9YCSaw2qC+4bsnYa2W6hY21Z/1e3f/5ATzf0094OvIjP39VoePHK6WtL5ghDoMQMQ0zQM4TZXXoDU5B3oGbQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=6NCmwzRxUZxj7QXmRjne6tZZQ2qoBPGGgz46uHbX0ZM=; b=qs8E4qzysNRGNZ2puEY3YkMd0xOr4OgKoBrEdb++/Hfa1eNaX05jHz8LQLqJpd5XVtTMQjx+5T3D5RNXSm/xyRUsNrLmReemLzmXbJBe4+uACHS86KHGEshkYhCsohdnOPr6ldRcfhmJWMbHSiIxfK13wHF2pLpDOGNLG+ov9oRGyvAxqx8VOFkTFmrHr3TnKUgOgLH/h78D26P7F5Deh0xGPU23dnpYQnt94YY9+ZEgPC1/qWQ5IyOI+drYujfVp7VVyQGfsQZXPan9AioQ/bv1CSuBNIPKiw2eYUS8t8XwppTdPSuwwKXNp+Wc1GuEhT5mRjzoSGL8P+Rk+7R7xA== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 4.158.2.129) smtp.rcpttodomain=sourceware.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dmarc=[1,1,header.from=arm.com]) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=6NCmwzRxUZxj7QXmRjne6tZZQ2qoBPGGgz46uHbX0ZM=; b=V+aqhM/lH1F63cdT7C8W0CcgI+gNuzjbX2uKEZMwFvwlxgFho5/GuFXRoGO4p3RO6w9rg6IqFyidtVeZ/q3xSxz+WQIPLQZZkDCN3G+sWfDGfZ/AkxWP0gXIb/hfTw9n4eOshaVLCHIrl0FedjtXevH6QVWgl7+dJH3wmqkFt4Q= Received: from DUZPR01CA0069.eurprd01.prod.exchangelabs.com (2603:10a6:10:3c2::12) by GV2PR08MB11314.eurprd08.prod.outlook.com (2603:10a6:150:2c8::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.315.15; Fri, 14 Aug 2026 10:50:18 +0000 Received: from DB5PEPF00014B94.eurprd02.prod.outlook.com (2603:10a6:10:3c2:cafe::25) by DUZPR01CA0069.outlook.office365.com (2603:10a6:10:3c2::12) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.315.16 via Frontend Transport; Fri, 14 Aug 2026 10:50:18 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 4.158.2.129) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=arm.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 4.158.2.129 as permitted sender) receiver=protection.outlook.com; client-ip=4.158.2.129; helo=outbound-uk1.az.dlp.m.darktrace.com; pr=C Received: from outbound-uk1.az.dlp.m.darktrace.com (4.158.2.129) by DB5PEPF00014B94.mail.protection.outlook.com (10.167.8.232) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.339.3 via Frontend Transport; Fri, 14 Aug 2026 10:50:17 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=hPWICaC2VBJF/Fq/dTyAvs4bsD0SdA/hW+aEFvvFZp1RBQniGRQrzkicmwjfyr25wboe/qP2c0mPtBUAYT6s0OHhtG3FSvArfXNbM5+3WleUK9BY3UA95+RTNYd9d9ZW08xtxW/nTALI/3qRrPAl1gX3WJ2Fn7JQH+tjagy4Y2PfNcHNmgkNeb+/t4mDT0ZP4pl7tvA5ekfDmyXwPSb6JHyHoVM3vz62XEEW+gDThdIQ6PYf9HpsRNJUyw7aph2KS9aJsJ+IP9LBQmeeswtSoNdbLPspOEaVJvhDOGQkNijMon2cImFalAWKUT5me/a0+C+BZ2B29vCb40HHTbRDYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=6NCmwzRxUZxj7QXmRjne6tZZQ2qoBPGGgz46uHbX0ZM=; b=U6Rpcp5OcCMLjlXsz5GcD6/YIRF+rcLi/aD6am0N8uTRPh89T1U1Mt8Ng1sZ+3MTNjsO7WZQVXOpai0vLJx+Iq0esIOVNSqW59dAHYPoouCxn3o7WV09lTmK9Z1upmzxqPCROgXHDw28t0SHXB+5mDqI6MNXhEVGeRJ8IY/AXhkVJXbez//5bYmNw/ckm/saIWUxng9OcmczcmmNMWqacjmDybEHkP+KADW/ORFY06YJi3/uWR95LngEmrO3K/kY1dOR34eox+z0DpDxHFHJ7/fWkOTS+4TsDJVO+XnuTcjsiN22mP1FiAO41oqVUYdSHovyPHdaxItwM5Pl2XvhUA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 172.205.89.229) smtp.rcpttodomain=sourceware.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=6NCmwzRxUZxj7QXmRjne6tZZQ2qoBPGGgz46uHbX0ZM=; b=V+aqhM/lH1F63cdT7C8W0CcgI+gNuzjbX2uKEZMwFvwlxgFho5/GuFXRoGO4p3RO6w9rg6IqFyidtVeZ/q3xSxz+WQIPLQZZkDCN3G+sWfDGfZ/AkxWP0gXIb/hfTw9n4eOshaVLCHIrl0FedjtXevH6QVWgl7+dJH3wmqkFt4Q= Received: from AM0P190CA0024.EURP190.PROD.OUTLOOK.COM (2603:10a6:208:190::34) by PAVPR08MB9627.eurprd08.prod.outlook.com (2603:10a6:102:31b::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.315.15; Fri, 14 Aug 2026 10:49:44 +0000 Received: from AMS1EPF00000094.eurprd05.prod.outlook.com (2603:10a6:208:190:cafe::4d) by AM0P190CA0024.outlook.office365.com (2603:10a6:208:190::34) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.315.15 via Frontend Transport; Fri, 14 Aug 2026 10:49:44 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 172.205.89.229) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 172.205.89.229 as permitted sender) receiver=protection.outlook.com; client-ip=172.205.89.229; helo=nebula.arm.com; pr=C Received: from nebula.arm.com (172.205.89.229) by AMS1EPF00000094.mail.protection.outlook.com (10.167.242.91) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.339.3 via Frontend Transport; Fri, 14 Aug 2026 10:49:44 +0000 Received: from AZ-NEU-EXJ02.Arm.com (10.240.25.139) by AZ-NEU-EX03.Arm.com (10.240.25.137) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Fri, 14 Aug 2026 10:49:44 +0000 Received: from AZ-NEU-EX03.Arm.com (10.240.25.137) by AZ-NEU-EXJ02.Arm.com (10.240.25.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Fri, 14 Aug 2026 10:49:44 +0000 Received: from PF4S4363.arm.com (10.57.46.138) by mail.arm.com (10.240.25.137) with Microsoft SMTP Server id 15.2.2562.29 via Frontend Transport; Fri, 14 Aug 2026 10:49:43 +0000 From: Matthieu Longo To: CC: Simon Marchi , Matthieu Longo Subject: [PATCH v2] gdbtypes: improve documentation of composite type helpers Date: Fri, 14 Aug 2026 11:49:41 +0100 Message-ID: <20260814104941.522777-1-matthieu.longo@arm.com> X-Mailer: git-send-email 2.55.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: AMS1EPF00000094:EE_|PAVPR08MB9627:EE_|DB5PEPF00014B94:EE_|GV2PR08MB11314:EE_ X-MS-Office365-Filtering-Correlation-Id: 3f02781d-8762-4ab1-1f4f-08def9f1d462 x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; ARA:13230040|36860700016|23010399003|82310400026|1800799024|376014|56012099006|10067099003|6133799003|18002099003|11063799006; X-Microsoft-Antispam-Message-Info-Original: xu7R4H99m9ytWvgVkEF0JxeQKddeCMM48dOKNb1EtI4CrGmdEAeKaJeOrG/FQKPpH+hfXio7LyN1dwh3hhkcsnm3FoT0CqG6bQFvs4Y/FvYAKE0INKF7QKbAoWJJDfQpnD5wDzox+kWlZvLRNLTHZe2vFGhixiBcHXXKN8IG45wThvx2SRSITdNuLijSsBBlpkMcPzRwrL/UJ07U+bl+l1iyNMJZTSzI9s2YT6zMt2nJD78//nkcoeVkl6oRbX9ly9u8w1Tj7ljeTNZMRcX2VrkgJeIGoVDZVv1ShwJ2hSwdx6CHEGVmDNWh/4nRw9noVQMbaJBMsaesuS6V+XshYWRWQpuW8rWhW7yk6I/C6wd9I0fesCp6eMpSDbYL83UiK7hJVzQIGieEaMHbLvRArgGK3+IEdS6iY6q1UdSAHe0bxlbIFK3x1/P/28GGfocMkrYVyvTmldj9SYsi72r8ziRDhNmN3WMd5FmboRcdTQFoUywes92DRFL0mlQcJTbRGlxjmB8kLoQlSJPOXmi5J51ooE8bIz1vEopN72yV/+YKUYvkEpmak/w63qL3V3rwb869jb3d7nT10H73pQa7RNEWt47gndC15UJZon8yOJseawzrOiyCKASLdt+EK289hVUcfvzV5eb6fMZyVbcrmobw0tZulfTx2W3QxFB9nbhhWc68NCaRA3twVVUAiIxyiSblQNCnPISYV2oUMXNyMQ== X-Forefront-Antispam-Report-Untrusted: CIP:172.205.89.229; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(36860700016)(23010399003)(82310400026)(1800799024)(376014)(56012099006)(10067099003)(6133799003)(18002099003)(11063799006); DIR:OUT; SFP:1101; X-Exchange-RoutingPolicyChecked: RB4OFj+zjr/wLuKrMfpXNjC+h7vaneLhmoGyEdhVqLKsOjjDUBjV33lSJAEYvF1ZQ4UjWcNiXb4NY99y/whtn/f2Cynj4Wz4iOmweKQlixMr9quLCmrQYIhos8JjcqiKhDqMSqXIf0+TETxvvPrBd6LZzSJbmPzqGaCdtrZQYKGE17QDRExdwj5CmuNORIFfsH2ljTFYTs6lBdLmEtVhouOzk8erw6AC8xB3jjAcHFfgrmlW73uCjrPb1TaC6aAgU5KmyuG2lJYb+V9rb3RVmX+LX109Ow+pqzWspc7B96GamxovsTfm5UazSNND09jewjQuRqkz8NqXMmo71DmM3Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAVPR08MB9627 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB5PEPF00014B94.eurprd02.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 43cbd1e3-1479-48c3-2a33-08def9f1c095 X-Microsoft-Antispam: BCL:0; ARA:13230040|14060799003|1800799024|82310400026|35042699022|23010399003|376014|36860700016|18002099003|56012099006|6133799003|11063799006|10067099003; X-Microsoft-Antispam-Message-Info: 6MDwSY5jPS3cKb/OLhWbTXfQxGa/2NFb4M5PMMs40UyRhal3bKcCo/VE3xIXOKM1/UqOyH22XePS/jEQzLjYIlRUSbBstkeOKFIVJbhDxOZDZ6YNWXUv2FxzurQ6rWGfqA3aK/T+PcGJHIQPVa068bTbmjz+CYMHGWnf63GSA88Pn98UKZW8OR7r8MWPMSPJdDTkmtDLzHdzS55CleZXeoJdu6HOVOSP+5dC02jr4xmFETJcOf1ZsmN7Wi1LrXbXkCiUcDRopc1zTl83qFR+ooN5+IqRB6L0OYlqLwqIkKzHMvqJeiyWSqfm+AIn83KdtUuUOo0iiOJq2ztc5o/KxYlD8cFCh+KgUCy+frJjLzUAXvMZcMZb4EpCnxrRJEPeIxe5LJFTIDgUvMKNh0Upg50uiWqPFg9Iqo3+97R8xtgXvOcnWGrjw956Yq3V2n+Ef9a9N4Eg35tNw8Yz0WY12TMQhgby1S23/9Pavp833BWi8UfkTZRoWUbQTJMJtZ4sT82zH01sN9lNCo3G/8UayGX5Ajndu0gGDvbDjS5MCbjB3c22vpdjq/9OWQNfnrcmndikVh2Frf51Uqd3q1rRgxf9AZ3Y5h2cZGR8hisZeFe+GHBtqGjgkUnwQMt67Iv1guhLN0S4d8cBCzIoAmJO+t45YkUPTN375nQEacuem/D1srgW8EErcOQnq+0fMXIyO+QWy73lrRwPusdsV89YGQ== X-Forefront-Antispam-Report: CIP:4.158.2.129; CTRY:GB; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:outbound-uk1.az.dlp.m.darktrace.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(14060799003)(1800799024)(82310400026)(35042699022)(23010399003)(376014)(36860700016)(18002099003)(56012099006)(6133799003)(11063799006)(10067099003); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: UnX1pD5o3orkO76ENaAx8ZrJ74zs+zPXaIhsf8tBCgIM0cM9QRliI5QTunECua0GcvunnSrqCLGPgBauS1fQfb9+HyCzZ0TY1pC7UjLtPti3cjyjlAn2Fl0huYIM2xWJaMWS95qxDvTUA0q60HCIRo3LoyMWBC0l3gxl54CXROFez+KODnhaixSo/uYt9tIUgydyvp72x8lt+iOdopxWSk5DDxAg0fzZHlz+s1td8/k/3vj/rbv4wkNzE12uNNxtn8N5C+GEaJXrcIjIF+ezpFwZN6er6kVX3FiG040qDX6tf3lsD9ZrbHV5Zu0mWzr6Ufsyuyg1i1gyo/IktDRo60UsTGq7bW/Kn60Zbe9O/B6hSy0xSVCV9UKIQVgUBIcGfWEppO+l/xRroX99r/yw6Bgu11s2a/IxJPNdqTO4Z6/UOPZ0b2I9uLmun3L+HW2O X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Aug 2026 10:50:17.8356 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3f02781d-8762-4ab1-1f4f-08def9f1d462 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[4.158.2.129]; Helo=[outbound-uk1.az.dlp.m.darktrace.com] X-MS-Exchange-CrossTenant-AuthSource: DB5PEPF00014B94.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: GV2PR08MB11314 X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org Document how arch_composite_type handles a null NAME, and clarify the semantics of an empty field name for the append_composite_type* helpers. Suggested-By: Simon Marchi --- gdb/gdbtypes.c | 12 ++++-------- gdb/gdbtypes.h | 30 ++++++++++++++++++++++++++---- 2 files changed, 30 insertions(+), 12 deletions(-) diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c index 4b6c01910f4..e0c25c58d83 100644 --- a/gdb/gdbtypes.c +++ b/gdb/gdbtypes.c @@ -5412,8 +5412,7 @@ append_flags_type_flag (struct type *type, int bitpos, const char *name) name); } -/* Allocate a TYPE_CODE_STRUCT or TYPE_CODE_UNION type structure (as - specified by CODE) associated with GDBARCH. NAME is the type name. */ +/* See gdbtypes.h. */ struct type * arch_composite_type (struct gdbarch *gdbarch, const char *name, @@ -5428,9 +5427,7 @@ arch_composite_type (struct gdbarch *gdbarch, const char *name, return t; } -/* Add new field with name NAME and type FIELD to composite type T. - Do not set the field's position or adjust the type's length; - the caller should do so. Return the new field. */ +/* See gdbtypes.h. */ struct field * append_composite_type_field_raw (struct type *t, const char *name, @@ -5448,8 +5445,7 @@ append_composite_type_field_raw (struct type *t, const char *name, return f; } -/* Add new field with name NAME and type FIELD to composite type T. - ALIGNMENT (if non-zero) specifies the minimum field alignment. */ +/* See gdbtypes.h. */ void append_composite_type_field_aligned (struct type *t, const char *name, @@ -5489,7 +5485,7 @@ append_composite_type_field_aligned (struct type *t, const char *name, } } -/* Add new field with name NAME and type FIELD to composite type T. */ +/* See gdbtypes.h. */ void append_composite_type_field (struct type *t, const char *name, diff --git a/gdb/gdbtypes.h b/gdb/gdbtypes.h index dd2d24fa8e2..f7853430d64 100644 --- a/gdb/gdbtypes.h +++ b/gdb/gdbtypes.h @@ -2431,20 +2431,42 @@ extern struct type *init_pointer_type (type_allocator &alloc, int bit, extern struct type *init_fixed_point_type (type_allocator &, int, int, const char *); -/* Helper functions to construct a struct or record type. An - initially empty type is created using arch_composite_type(). - Fields are then added using append_composite_type_field*(). A union - type has its size set to the largest field. A struct type has each +/* Helper functions to construct a struct or record type. An initially empty + type is created using arch_composite_type(). Fields are then added using + append_composite_type_field*(). + A union type has its size set to the largest field. A struct type has each field packed against the previous. */ +/* Allocate a TYPE_CODE_STRUCT or TYPE_CODE_UNION type structure (as + specified by CODE) associated with GDBARCH. NAME is the type name. + If NAME is nullptr, the type is anonymous. */ + extern struct type *arch_composite_type (struct gdbarch *gdbarch, const char *name, enum type_code code); + +/* Add a new field named NAME with type FIELD to composite type T. + If NAME is an empty string, the field represents an anonymous struct or + union whose fields are visible directly in the parent scope. */ + extern void append_composite_type_field (struct type *t, const char *name, struct type *field); + +/* Add a new field named NAME with type FIELD to composite type T. + ALIGNMENT (if non-zero) specifies the minimum field alignment. + If NAME is an empty string, the field represents an anonymous struct or + union whose fields are visible directly in the parent scope. */ + extern void append_composite_type_field_aligned (struct type *t, const char *name, struct type *field, int alignment); + +/* Add a new field named NAME with type FIELD to composite type T. + This function does not set the field's position or adjust the length of T; + the caller is responsible for doing so. If NAME is an empty string, the + field represents an anonymous struct or union whose fields are visible + directly in the parent scope. Return the newly added field. */ + struct field *append_composite_type_field_raw (struct type *t, const char *name, struct type *field); -- 2.55.0