From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-il1-x12e.google.com (mail-il1-x12e.google.com [IPv6:2607:f8b0:4864:20::12e]) by sourceware.org (Postfix) with ESMTPS id 1EED63858D35 for ; Mon, 24 Apr 2023 16:22:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1EED63858D35 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com Received: by mail-il1-x12e.google.com with SMTP id e9e14a558f8ab-3296292e623so39469675ab.2 for ; Mon, 24 Apr 2023 09:22:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1682353344; x=1684945344; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=NBqx31RzDvP8TfotwB78G1smLiBBkFKalR0JktnOCws=; b=hazYh72ZIuMZAMfiAGuCZK6CT39khclGvhmnu7QZEDcei4O5/2BvuswVAnRZVcDM1r 5EZX4Qq1dr6gCLlnjZyuN+x862XAkE5xKwHuzYyiDtmFqVfXiTBdl1trZzslvzpxgiq1 TYbztK4Ndw92brdE47TylI8VZmeBISM5F1uCq2RM258tjvXnRZkLuADCWorMYdcubD0R Sql3CA65XR6FVETcFU7RfxGya7iUbXtgqZOocPW8dsHobELKuCoEahOqhMHTWh3nK0f2 uMc7kKbur8SfBvkz7W2078RHN09A4RxZ4Sd8p6bQUXMSc0ItU6QOq0UmFbfLyFJUBFjN BMnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682353344; x=1684945344; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=NBqx31RzDvP8TfotwB78G1smLiBBkFKalR0JktnOCws=; b=EafYbLHjy36JS6nXWo6uHV9IgWn4uBD0LXizFx4eGKjpIs8xxVH/gfXABOxZzthe3W Ei5Q6R16Z75aZvrddTRZDvroDPqLDyZw90sF/nqIIrdNcbCbVkslRLMU9fMRshNu2/xc dsYU+1E1Kw8axBY6jg+GmavfncboFCj9oy/FMwoDGrwBdOKk4PVvWKKRojjiEIEPlXFj aczMSawpxHSlwevihsEO1yQWwChsNAV2Lsi4y/OEwkXAYVK1htJULJe4ZsuwlmezxxcE LK/c7JLxpswLXp2ZxJpfsN5cRTZJrfdjz/LSwtLCHMBkXC9nw3CRxii2BIcDfirHMR5c 4RxQ== X-Gm-Message-State: AAQBX9fNkABHRg2r4qgPpQglK/RJenqUtcsHQkdnoz8nRCvnUFKKyxIc ApX3YjdLxgl+3j5ZoxPDbz2GFAo+tbDbKSom7eIhag== X-Google-Smtp-Source: AKy350Zw4dhefYWs+bFjx0A230mHFa+OU/WndAT3cLcsbUzDUWM/0yTFHQCePUCUluGyTzWQMrGBRQ== X-Received: by 2002:a92:502:0:b0:328:a646:8bf5 with SMTP id q2-20020a920502000000b00328a6468bf5mr5460773ile.27.1682353344253; Mon, 24 Apr 2023 09:22:24 -0700 (PDT) Received: from localhost.localdomain (71-211-191-82.hlrn.qwest.net. [71.211.191.82]) by smtp.gmail.com with ESMTPSA id cx27-20020a056638491b00b0040fa19472bcsm3444049jab.92.2023.04.24.09.22.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Apr 2023 09:22:23 -0700 (PDT) From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [RFC 03/10] Move unrelocated_addr to common-types.h Date: Mon, 24 Apr 2023 10:22:04 -0600 Message-Id: <20230424162211.682763-4-tromey@adacore.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230424162211.682763-1-tromey@adacore.com> References: <20230424162211.682763-1-tromey@adacore.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-11.3 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 List-Id: unrelocated_addr is currently defined in symtab.h, but in order to avoid having to include that in more places, I wanted to move the type elsewhere. I considered defs.h, but it seemed reasonable to have it next to CORE_ADDR, which is what this patch does. --- gdb/symtab.h | 6 ------ gdbsupport/common-types.h | 6 ++++++ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gdb/symtab.h b/gdb/symtab.h index 404d0ab30a8..495e7522e25 100644 --- a/gdb/symtab.h +++ b/gdb/symtab.h @@ -58,12 +58,6 @@ class probe; struct lookup_name_info; struct code_breakpoint; -/* Like a CORE_ADDR, but not directly convertible. This is used to - represent an unrelocated CORE_ADDR. DEFINE_OFFSET_TYPE is not used - here because there's no need to add or subtract values of this - type. */ -enum class unrelocated_addr : CORE_ADDR { }; - /* How to match a lookup name against a symbol search name. */ enum class symbol_name_match_type { diff --git a/gdbsupport/common-types.h b/gdbsupport/common-types.h index 4156021abb4..3717162b36b 100644 --- a/gdbsupport/common-types.h +++ b/gdbsupport/common-types.h @@ -28,6 +28,12 @@ typedef unsigned char gdb_byte; /* * An address in the program being debugged. Host byte order. */ typedef uint64_t CORE_ADDR; +/* Like a CORE_ADDR, but not directly convertible. This is used to + represent an unrelocated CORE_ADDR. DEFINE_OFFSET_TYPE is not used + here because there's no need to add or subtract values of this + type. */ +enum class unrelocated_addr : CORE_ADDR { }; + /* LONGEST must be at least as big as CORE_ADDR. */ typedef int64_t LONGEST; -- 2.39.1