From 140eb481d1c31d9327b7baf7901c354c8e224dab Mon Sep 17 00:00:00 2001 From: Simon Marchi Date: Thu, 18 Nov 2021 16:35:34 -0500 Subject: [PATCH] gdb: fix array-view-selftests.c build with g++ 4.8 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 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 typename Container> +template class Container> static constexpr bool check_ctor_from_container () { -- 2.30.2