From: Simon Marchi <simon.marchi@efficios.com>
To: gdb-patches@sourceware.org
Cc: Simon Marchi <simon.marchi@efficios.com>
Subject: [PATCH 2/2] gdb: fix array-view-selftests.c build with g++ 4.8
Date: Thu, 18 Nov 2021 15:50:53 -0500 [thread overview]
Message-ID: <20211118205053.2429353-2-simon.marchi@efficios.com> (raw)
In-Reply-To: <20211118205053.2429353-1-simon.marchi@efficios.com>
When building with g++ 4.8, I get:
CXX unittests/array-view-selftests.o
/home/smarchi/src/binutils-gdb/gdb/unittests/array-view-selftests.c:123:42: error: expected 'class' before 'Container'
template<template<typename ...> typename Container>
^
I am no C++ template expert, but it looks like if I change "typename" for
"class", as the compiler kind of suggests, the code compiles.
Change-Id: I9c3edd29fb2b190069f0ce0dbf3bc3604d175f48
---
gdb/unittests/array-view-selftests.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gdb/unittests/array-view-selftests.c b/gdb/unittests/array-view-selftests.c
index fe211a647b5..9df48db3912 100644
--- a/gdb/unittests/array-view-selftests.c
+++ b/gdb/unittests/array-view-selftests.c
@@ -120,7 +120,7 @@ check ()
/* Check that there's no container->view conversion for containers of derived
types or subclasses. */
-template<template<typename ...> typename Container>
+template<template<typename ...> class Container>
static constexpr bool
check_ctor_from_container ()
{
--
2.33.1
next prev parent reply other threads:[~2021-11-18 20:50 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-18 20:50 [PATCH 1/2] gdb: fix ia64-tdep.c " Simon Marchi
2021-11-18 20:50 ` Simon Marchi [this message]
2021-11-18 21:11 ` [PATCH 2/2] gdb: fix array-view-selftests.c " Lancelot SIX
2021-11-18 21:36 ` Simon Marchi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211118205053.2429353-2-simon.marchi@efficios.com \
--to=simon.marchi@efficios.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).