https://bugs.gentoo.org/894376 https://gitlab.gnome.org/GNOME/libgee/-/commit/2f0bbe8987e5eb1390b23ac531c971b202c2ef77 From 2f0bbe8987e5eb1390b23ac531c971b202c2ef77 Mon Sep 17 00:00:00 2001 From: Rico Tzschichholz Date: Thu, 13 Apr 2023 23:43:03 +0200 Subject: [PATCH] Implementations of "G List.get()" should use non-nullable return as defined --- a/gee/abstractlist.vala +++ b/gee/abstractlist.vala @@ -39,7 +39,7 @@ public abstract class Gee.AbstractList : Gee.AbstractCollection, List { /** * {@inheritDoc} */ - public abstract new G? get (int index); + public abstract new G get (int index); /** * {@inheritDoc} --- a/gee/concurrentlist.vala +++ b/gee/concurrentlist.vala @@ -170,7 +170,7 @@ public class Gee.ConcurrentList : AbstractList { /** * {@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); --- a/gee/readonlylist.vala +++ b/gee/readonlylist.vala @@ -74,7 +74,7 @@ internal class Gee.ReadOnlyList : Gee.ReadOnlyCollection, List { /** * {@inheritDoc} */ - public new G? get (int index) { + public new G get (int index) { return ((Gee.List) _collection).get (index); } --- a/gee/unrolledlinkedlist.vala +++ b/gee/unrolledlinkedlist.vala @@ -158,7 +158,7 @@ public class Gee.UnrolledLinkedList : AbstractBidirList, Queue, Deque (this); } - public override G? get (int index) { + public override G get (int index) { assert (index >= 0); assert (index < this._size); -- GitLab