From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1879) id 4815C3858D38; Tue, 23 Apr 2024 01:37:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4815C3858D38 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1713836264; bh=peiOvwu4Y8YHbF9sG+ybwPsb8OiZ4tu8SpecMOO66HU=; h=From:To:Subject:Date:From; b=mVXrkkguh3VYF5Cc8zagBxN+5OVoChb4rTHSDvlSyfvmypHdG26/dNCpq92LgP28r STwIve+TMVI0JLVPjhA9GWU7+AF1zToLz965YKtTSF1POU48Ed5RJiJ8nzE1ow3hdc Jgqc0qwfohTh4GRVnge7LK+DT7DkVuIREJD0X45Y= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Simon Marchi To: gdb-cvs@sourceware.org Subject: [binutils-gdb] gdb: move RequireLongest to gdbsupport/traits.h X-Act-Checkin: binutils-gdb X-Git-Author: Simon Marchi X-Git-Refname: refs/heads/master X-Git-Oldrev: ec4525259262492b61fb9bd2f9acdf156ab037fc X-Git-Newrev: 6e7c49c2dd9ab0803894925c2ec422ea5aeddfb8 Message-Id: <20240423013744.4815C3858D38@sourceware.org> Date: Tue, 23 Apr 2024 01:37:44 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3D6e7c49c2dd9a= b0803894925c2ec422ea5aeddfb8 commit 6e7c49c2dd9ab0803894925c2ec422ea5aeddfb8 Author: Simon Marchi Date: Mon Apr 22 16:10:15 2024 -0400 gdb: move RequireLongest to gdbsupport/traits.h =20 Move it out of defs.h. =20 Change-Id: Ie1743d41a57f81667650048563e66073c72230cf Approved-By: John Baldwin Diff: --- gdb/defs.h | 4 ---- gdb/extract-store-integer.h | 2 ++ gdb/regcache.h | 1 + gdbsupport/traits.h | 4 ++++ 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/gdb/defs.h b/gdb/defs.h index 5da8ce72815..535ca671673 100644 --- a/gdb/defs.h +++ b/gdb/defs.h @@ -63,10 +63,6 @@ #include "gdbsupport/enum-flags.h" #include "gdbsupport/array-view.h" =20 -template -using RequireLongest =3D gdb::Requires, - std::is_same>>; - /* Just in case they're not defined in stdio.h. */ =20 #ifndef SEEK_SET diff --git a/gdb/extract-store-integer.h b/gdb/extract-store-integer.h index 1ba5f82da9a..fd195dc6436 100644 --- a/gdb/extract-store-integer.h +++ b/gdb/extract-store-integer.h @@ -18,6 +18,8 @@ #ifndef GDB_EXTRACT_STORE_INTEGER_H #define GDB_EXTRACT_STORE_INTEGER_H =20 +#include "gdbsupport/traits.h" + template> T extract_integer (gdb::array_view, enum bfd_endian byte_o= rder); =20 diff --git a/gdb/regcache.h b/gdb/regcache.h index 1d049fe7ae8..2f4b7d94c69 100644 --- a/gdb/regcache.h +++ b/gdb/regcache.h @@ -23,6 +23,7 @@ #include "gdbsupport/array-view.h" #include "gdbsupport/common-regcache.h" #include "gdbsupport/function-view.h" +#include "gdbsupport/traits.h" =20 struct regcache; struct regset; diff --git a/gdbsupport/traits.h b/gdbsupport/traits.h index 92fe59f34af..85cbc94bc6c 100644 --- a/gdbsupport/traits.h +++ b/gdbsupport/traits.h @@ -143,4 +143,8 @@ template using Requires =3D typename std::enable_if::type; } =20 +template +using RequireLongest =3D gdb::Requires, + std::is_same>>; + #endif /* COMMON_TRAITS_H */