forked from pool/libgee
Compare commits
2 Commits
| Author | SHA256 | Date | |
|---|---|---|---|
| ce4fd2b5dd | |||
| 017cfdaeb6 |
@@ -1,68 +0,0 @@
|
||||
From 2f0bbe8987e5eb1390b23ac531c971b202c2ef77 Mon Sep 17 00:00:00 2001
|
||||
From: Rico Tzschichholz <ricotz@ubuntu.com>
|
||||
Date: Thu, 13 Apr 2023 23:43:03 +0200
|
||||
Subject: [PATCH] Implementations of "G List.get()" should use non-nullable
|
||||
return as defined
|
||||
|
||||
---
|
||||
gee/abstractlist.vala | 2 +-
|
||||
gee/concurrentlist.vala | 2 +-
|
||||
gee/readonlylist.vala | 2 +-
|
||||
gee/unrolledlinkedlist.vala | 2 +-
|
||||
4 files changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/gee/abstractlist.vala b/gee/abstractlist.vala
|
||||
index eeff984..1e55114 100644
|
||||
--- a/gee/abstractlist.vala
|
||||
+++ b/gee/abstractlist.vala
|
||||
@@ -39,7 +39,7 @@ public abstract class Gee.AbstractList<G> : Gee.AbstractCollection<G>, List<G> {
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
- public abstract new G? get (int index);
|
||||
+ public abstract new G get (int index);
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
diff --git a/gee/concurrentlist.vala b/gee/concurrentlist.vala
|
||||
index 6e511f1..583f827 100644
|
||||
--- a/gee/concurrentlist.vala
|
||||
+++ b/gee/concurrentlist.vala
|
||||
@@ -170,7 +170,7 @@ public class Gee.ConcurrentList<G> : AbstractList<G> {
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
- public override G? get (int index) {
|
||||
+ public override G get (int index) {
|
||||
HazardPointer.Context ctx = new HazardPointer.Context ();
|
||||
Utils.Misc.unused (ctx);
|
||||
assert (index >= 0);
|
||||
diff --git a/gee/readonlylist.vala b/gee/readonlylist.vala
|
||||
index 8be3f27..c243d14 100644
|
||||
--- a/gee/readonlylist.vala
|
||||
+++ b/gee/readonlylist.vala
|
||||
@@ -74,7 +74,7 @@ internal class Gee.ReadOnlyList<G> : Gee.ReadOnlyCollection<G>, List<G> {
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
- public new G? get (int index) {
|
||||
+ public new G get (int index) {
|
||||
return ((Gee.List<G>) _collection).get (index);
|
||||
}
|
||||
|
||||
diff --git a/gee/unrolledlinkedlist.vala b/gee/unrolledlinkedlist.vala
|
||||
index e36f88f..234d24d 100644
|
||||
--- a/gee/unrolledlinkedlist.vala
|
||||
+++ b/gee/unrolledlinkedlist.vala
|
||||
@@ -158,7 +158,7 @@ public class Gee.UnrolledLinkedList<G> : AbstractBidirList<G>, Queue<G>, Deque<G
|
||||
return new Iterator<G> (this);
|
||||
}
|
||||
|
||||
- public override G? get (int index) {
|
||||
+ public override G get (int index) {
|
||||
assert (index >= 0);
|
||||
assert (index < this._size);
|
||||
|
||||
--
|
||||
GitLab
|
||||
|
||||
@@ -1,53 +0,0 @@
|
||||
From b33a6627f4fc96938b6015e05849867c472160a8 Mon Sep 17 00:00:00 2001
|
||||
From: Rico Tzschichholz <ricotz@ubuntu.com>
|
||||
Date: Sat, 8 Apr 2023 22:39:35 +0200
|
||||
Subject: [PATCH] Add more missing generic type arguments
|
||||
|
||||
---
|
||||
gee/hashmap.vala | 2 +-
|
||||
gee/hashset.vala | 2 +-
|
||||
gee/linkedlist.vala | 2 +-
|
||||
3 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/gee/hashmap.vala b/gee/hashmap.vala
|
||||
index a7bae9f..19e3980 100644
|
||||
--- a/gee/hashmap.vala
|
||||
+++ b/gee/hashmap.vala
|
||||
@@ -253,7 +253,7 @@ public class Gee.HashMap<K,V> : Gee.AbstractMap<K,V> {
|
||||
for (int i = 0; i < _array_size; i++) {
|
||||
Node<K,V> node = (owned) _nodes[i];
|
||||
while (node != null) {
|
||||
- Node next = (owned) node.next;
|
||||
+ Node<K,V> next = (owned) node.next;
|
||||
node.key = null;
|
||||
node.value = null;
|
||||
node = (owned) next;
|
||||
diff --git a/gee/hashset.vala b/gee/hashset.vala
|
||||
index ef6d5a2..bf05519 100644
|
||||
--- a/gee/hashset.vala
|
||||
+++ b/gee/hashset.vala
|
||||
@@ -210,7 +210,7 @@ public class Gee.HashSet<G> : AbstractSet<G> {
|
||||
for (int i = 0; i < _array_size; i++) {
|
||||
Node<G> node = (owned) _nodes[i];
|
||||
while (node != null) {
|
||||
- Node next = (owned) node.next;
|
||||
+ Node<G> next = (owned) node.next;
|
||||
node.key = null;
|
||||
node = (owned) next;
|
||||
}
|
||||
diff --git a/gee/linkedlist.vala b/gee/linkedlist.vala
|
||||
index aff36b9..976977f 100644
|
||||
--- a/gee/linkedlist.vala
|
||||
+++ b/gee/linkedlist.vala
|
||||
@@ -233,7 +233,7 @@ public class Gee.LinkedList<G> : AbstractBidirList<G>, Queue<G>, Deque<G> {
|
||||
n.next.prev = n;
|
||||
this._head = (owned)n;
|
||||
} else {
|
||||
- weak Node prev = this._head;
|
||||
+ weak Node<G> prev = this._head;
|
||||
for (int i = 0; i < index - 1; i++) {
|
||||
prev = prev.next;
|
||||
}
|
||||
--
|
||||
GitLab
|
||||
|
||||
@@ -1,89 +0,0 @@
|
||||
From ce8461ff6ea8ed79ce06b4241cb4fbb6d3d314f1 Mon Sep 17 00:00:00 2001
|
||||
From: Rico Tzschichholz <ricotz@ubuntu.com>
|
||||
Date: Wed, 20 Mar 2024 12:43:47 +0100
|
||||
Subject: [PATCH] Drop unsupported inline modifier on constructor and
|
||||
destructor declarations
|
||||
|
||||
---
|
||||
gee/concurrentlist.vala | 6 +++---
|
||||
gee/concurrentset.vala | 6 +++---
|
||||
gee/hazardpointer.vala | 2 +-
|
||||
3 files changed, 7 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/gee/concurrentlist.vala b/gee/concurrentlist.vala
|
||||
index 583f827..9b5c0f9 100644
|
||||
--- a/gee/concurrentlist.vala
|
||||
+++ b/gee/concurrentlist.vala
|
||||
@@ -420,7 +420,7 @@ public class Gee.ConcurrentList<G> : AbstractList<G> {
|
||||
}
|
||||
|
||||
private class Node<G> {
|
||||
- public inline Node (G data) {
|
||||
+ public Node (G data) {
|
||||
AtomicPointer.set (&_succ, null);
|
||||
AtomicPointer.set (&_backlink, null);
|
||||
G data_copy = data;
|
||||
@@ -431,7 +431,7 @@ public class Gee.ConcurrentList<G> : AbstractList<G> {
|
||||
AtomicPointer.set (&_data, (owned)data_ptr);
|
||||
}
|
||||
|
||||
- public inline Node.head () {
|
||||
+ public Node.head () {
|
||||
AtomicPointer.set (&_succ, null);
|
||||
AtomicPointer.set (&_backlink, null);
|
||||
AtomicPointer.set (&_data, null);
|
||||
@@ -440,7 +440,7 @@ public class Gee.ConcurrentList<G> : AbstractList<G> {
|
||||
#endif
|
||||
}
|
||||
|
||||
- inline ~Node () {
|
||||
+ ~Node () {
|
||||
HazardPointer.set_pointer<Node<G>?> (&_succ, null, 3);
|
||||
HazardPointer.set_pointer<Node<G>?> (&_backlink, null);
|
||||
#if DEBUG
|
||||
diff --git a/gee/concurrentset.vala b/gee/concurrentset.vala
|
||||
index 131d73e..465e566 100644
|
||||
--- a/gee/concurrentset.vala
|
||||
+++ b/gee/concurrentset.vala
|
||||
@@ -1145,14 +1145,14 @@ public class Gee.ConcurrentSet<G> : AbstractSortedSet<G> {
|
||||
}
|
||||
|
||||
private class Tower<G> {
|
||||
- public inline Tower (G data, uint8 height) {
|
||||
+ public Tower (G data, uint8 height) {
|
||||
_nodes = new TowerNode<G>[height];
|
||||
_data = data;
|
||||
_height = 0;
|
||||
AtomicPointer.set (&_nodes[0]._backlink, null); // FIXME: This should be memory barrier
|
||||
}
|
||||
|
||||
- public inline Tower.head () {
|
||||
+ public Tower.head () {
|
||||
_nodes = new TowerNode<G>[_MAX_HEIGHT];
|
||||
_height = -1;
|
||||
#if DEBUG
|
||||
@@ -1160,7 +1160,7 @@ public class Gee.ConcurrentSet<G> : AbstractSortedSet<G> {
|
||||
#endif
|
||||
}
|
||||
|
||||
- inline ~Tower () {
|
||||
+ ~Tower () {
|
||||
int height = get_height();
|
||||
for (uint8 i = 0; i < height; i++) {
|
||||
set_succ (null, State.NONE, i);
|
||||
diff --git a/gee/hazardpointer.vala b/gee/hazardpointer.vala
|
||||
index 3df5827..1710362 100644
|
||||
--- a/gee/hazardpointer.vala
|
||||
+++ b/gee/hazardpointer.vala
|
||||
@@ -733,7 +733,7 @@ public class Gee.HazardPointer<G> { // FIXME: Make it a struct
|
||||
AtomicInt.set (ref _active, 1);
|
||||
}
|
||||
|
||||
- inline ~Node () {
|
||||
+ ~Node () {
|
||||
delete _next;
|
||||
}
|
||||
|
||||
--
|
||||
GitLab
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:1bf834f5e10d60cc6124d74ed3c1dd38da646787fbf7872220b8b4068e476d4d
|
||||
size 690436
|
||||
BIN
libgee-0.20.8.tar.xz
LFS
Normal file
BIN
libgee-0.20.8.tar.xz
LFS
Normal file
Binary file not shown.
@@ -1,3 +1,14 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 16 19:57:40 UTC 2025 - Bjørn Lie <bjorn.lie@gmail.com>
|
||||
|
||||
- Update to version 0.20.8:
|
||||
+ Fixes for newer valac.
|
||||
- Drop patches fixed upstream:
|
||||
+ ce8461ff6ea8ed79ce06b4241cb4fbb6d3d314f1.patch
|
||||
+ b33a6627f4fc96938b6015e05849867c472160a8.patch
|
||||
+ 2f0bbe8987e5eb1390b23ac531c971b202c2ef77.patch
|
||||
- Add check section and run make check during build.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Jul 6 23:48:20 UTC 2024 - Bjørn Lie <bjorn.lie@gmail.com>
|
||||
|
||||
|
||||
13
libgee.spec
13
libgee.spec
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package libgee
|
||||
#
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
# Copyright (c) 2025 SUSE LLC
|
||||
# Copyright (c) 2010 Luis Medinas, Portugal
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
@@ -18,19 +18,13 @@
|
||||
|
||||
|
||||
Name: libgee
|
||||
Version: 0.20.6
|
||||
Version: 0.20.8
|
||||
Release: 0
|
||||
Summary: GObject-based library providing commonly used data structures
|
||||
License: LGPL-2.1-or-later
|
||||
Group: Development/Libraries/GNOME
|
||||
URL: https://wiki.gnome.org/Projects/Libgee
|
||||
Source0: https://download.gnome.org/sources/libgee/0.20/%{name}-%{version}.tar.xz
|
||||
# PATCH-FIX-UPSTREAM b33a6627f4fc96938b6015e05849867c472160a8.patch -- Add more missing generic type arguments
|
||||
Patch0: https://gitlab.gnome.org/GNOME/libgee/-/commit/b33a6627f4fc96938b6015e05849867c472160a8.patch
|
||||
# PATCH-FIX-UPSTREAM 2f0bbe8987e5eb1390b23ac531c971b202c2ef77.patch -- Implementations of "G List.get()" should use non-nullable return as defined
|
||||
Patch1: https://gitlab.gnome.org/GNOME/libgee/-/commit/2f0bbe8987e5eb1390b23ac531c971b202c2ef77.patch
|
||||
# PATCH-FIX-UPSTREAM ce8461ff6ea8ed79ce06b4241cb4fbb6d3d314f1.patch -- Drop unsupported inline modifier on constructor and destructor declarations
|
||||
Patch2: https://gitlab.gnome.org/GNOME/libgee/-/commit/ce8461ff6ea8ed79ce06b4241cb4fbb6d3d314f1.patch
|
||||
|
||||
BuildRequires: gobject-introspection-devel
|
||||
BuildRequires: pkgconfig
|
||||
@@ -90,6 +84,9 @@ find %{buildroot} -type f -name "*.la" -delete -print
|
||||
|
||||
%ldconfig_scriptlets -n libgee-0_8-2
|
||||
|
||||
%check
|
||||
make check
|
||||
|
||||
%files -n libgee-0_8-2
|
||||
%license COPYING
|
||||
%doc NEWS README
|
||||
|
||||
Reference in New Issue
Block a user