[folks] Remove implementation of LinkedHashSet.list_iterator()
- From: Philip Withnall <pwithnall src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [folks] Remove implementation of LinkedHashSet.list_iterator()
- Date: Sat, 16 Apr 2011 14:17:14 +0000 (UTC)
commit f311735144325c44de2c542415fcf65913d9e286
Author: Philip Withnall <philip withnall collabora co uk>
Date: Thu Mar 24 12:08:28 2011 +0000
Remove implementation of LinkedHashSet.list_iterator()
The extra methods provided by ListIterator are all incompatible with the
set qualities of LinkedHashSet, and would allow duplicate entries to be
introduced into the set.
LinkedHashSet.iterator() continues to return an iterator which uses the
links in LinkedHashSet to provide fast iteration.
Helps: bgo#645684
NEWS | 3 +++
folks/linked-hash-set.vala | 7 +++----
2 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/NEWS b/NEWS
index 584440c..18943a0 100644
--- a/NEWS
+++ b/NEWS
@@ -7,6 +7,9 @@ Bugs fixed:
* Bug 647121 â?? Crash in individual_store_contact_sort at
empathy-individual-store.c line 1387
+API changes:
+* LinkedHashSet.list_iterator() is now disallowed (causes an assertion failure)
+
Overview of changes from libfolks 0.4.0 to libfolks 0.5.0
=========================================================
diff --git a/folks/linked-hash-set.vala b/folks/linked-hash-set.vala
index c7cfc0b..ffb149d 100644
--- a/folks/linked-hash-set.vala
+++ b/folks/linked-hash-set.vala
@@ -281,16 +281,15 @@ public class Folks.LinkedHashSet<G> : AbstractList<G>,
}
/**
- * Returns the ListIterator for this structure.
+ * Unimplemented method (incompatible with ordered set).
*
- * @return a { link Gee.ListIterator} that can be used for iteration over this
- * structure (as a list).
+ * @return nothing
* @see Gee.ListIterator
*
* @since 0.3.4
*/
public override ListIterator<G> list_iterator ()
{
- return this._linked_list.list_iterator ();
+ assert_not_reached ();
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]