1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-23 03:05:48 +03:00
aports/community/openjdk22-loongarch/JDK-8331352_template-id.patch
2024-09-14 00:30:00 +00:00

68 lines
2.7 KiB
Diff

Patch-Source: https://github.com/openjdk/jdk22u/commit/2ec7dbf18e7d6bd746a82d61cd787d6344d3314e.patch
--
From 2ec7dbf18e7d6bd746a82d61cd787d6344d3314e Mon Sep 17 00:00:00 2001
From: Jan Kratochvil <jkratochvil@openjdk.org>
Date: Mon, 13 May 2024 20:47:07 +0000
Subject: [PATCH] 8331352: error: template-id not allowed for
constructor/destructor in C++20
Backport-of: 45792c5829fb1d5ee016c4a1fd6badb5d2b4239c
---
src/hotspot/share/gc/z/zArray.inline.hpp | 2 +-
src/hotspot/share/utilities/chunkedList.hpp | 2 +-
src/hotspot/share/utilities/events.hpp | 2 +-
src/hotspot/share/utilities/linkedlist.hpp | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/hotspot/share/gc/z/zArray.inline.hpp b/src/hotspot/share/gc/z/zArray.inline.hpp
index e4de7a37040..2ec87a76156 100644
--- a/src/hotspot/share/gc/z/zArray.inline.hpp
+++ b/src/hotspot/share/gc/z/zArray.inline.hpp
@@ -96,7 +96,7 @@ ZActivatedArray<T>::ZActivatedArray(bool locked)
_array() {}
template <typename T>
-ZActivatedArray<T>::~ZActivatedArray<T>() {
+ZActivatedArray<T>::~ZActivatedArray() {
FreeHeap(_lock);
}
diff --git a/src/hotspot/share/utilities/chunkedList.hpp b/src/hotspot/share/utilities/chunkedList.hpp
index 81898ac53b2..9a600e4ce1b 100644
--- a/src/hotspot/share/utilities/chunkedList.hpp
+++ b/src/hotspot/share/utilities/chunkedList.hpp
@@ -44,7 +44,7 @@ template <class T, MEMFLAGS F> class ChunkedList : public CHeapObj<F> {
}
public:
- ChunkedList<T, F>() : _top(_values), _next_used(nullptr), _next_free(nullptr) {}
+ ChunkedList() : _top(_values), _next_used(nullptr), _next_free(nullptr) {}
bool is_full() const {
return _top == end();
diff --git a/src/hotspot/share/utilities/events.hpp b/src/hotspot/share/utilities/events.hpp
index b400fd707fa..f7d2d193a86 100644
--- a/src/hotspot/share/utilities/events.hpp
+++ b/src/hotspot/share/utilities/events.hpp
@@ -99,7 +99,7 @@ template <class T> class EventLogBase : public EventLog {
EventRecord<T>* _records;
public:
- EventLogBase<T>(const char* name, const char* handle, int length = LogEventsBufferEntries):
+ EventLogBase(const char* name, const char* handle, int length = LogEventsBufferEntries):
_mutex(Mutex::event, name),
_name(name),
_handle(handle),
diff --git a/src/hotspot/share/utilities/linkedlist.hpp b/src/hotspot/share/utilities/linkedlist.hpp
index 5b8e258d539..eec7ea1e48d 100644
--- a/src/hotspot/share/utilities/linkedlist.hpp
+++ b/src/hotspot/share/utilities/linkedlist.hpp
@@ -82,7 +82,7 @@ template <class E> class LinkedListNode : public AnyObj {
template <class E> class LinkedList : public AnyObj {
protected:
LinkedListNode<E>* _head;
- NONCOPYABLE(LinkedList<E>);
+ NONCOPYABLE(LinkedList);
public:
LinkedList() : _head(nullptr) { }