Blame SOURCES/0001-Port-to-Java-8.patch

a67099
From 2da86d459a4806760d2883ed3c6296f904c80593 Mon Sep 17 00:00:00 2001
a67099
From: Michael Simacek <msimacek@redhat.com>
a67099
Date: Thu, 26 May 2016 15:43:14 +0200
a67099
Subject: [PATCH 1/2] Port to Java 8
a67099
a67099
---
a67099
 aQute.libg/src/aQute/lib/collections/DoubleKeyMap.java | 14 --------------
a67099
 aQute.libg/src/aQute/lib/collections/SortedList.java   |  6 ++++++
a67099
 biz.aQute.bnd/src/aQute/bnd/ant/BndTask.java           |  2 +-
a67099
 3 files changed, 7 insertions(+), 15 deletions(-)
a67099
a67099
diff --git a/aQute.libg/src/aQute/lib/collections/DoubleKeyMap.java b/aQute.libg/src/aQute/lib/collections/DoubleKeyMap.java
a67099
index 4107f31..40ecfdf 100644
a67099
--- a/aQute.libg/src/aQute/lib/collections/DoubleKeyMap.java
a67099
+++ b/aQute.libg/src/aQute/lib/collections/DoubleKeyMap.java
a67099
@@ -97,20 +97,6 @@ public class DoubleKeyMap<K1, K2, V> extends HashMap<K1,Map<K2,V>>implements Map
a67099
 		return result;
a67099
 	}
a67099
 
a67099
-	public V remove(K1 key1, K2 key2) {
a67099
-		assert k1Class.isInstance(key1);
a67099
-		assert k2Class.isInstance(key2);
a67099
-
a67099
-		Map<K2,V> set = get(key1);
a67099
-		if (set == null) {
a67099
-			return null;
a67099
-		}
a67099
-		V result = set.remove(key2);
a67099
-		if (set.isEmpty())
a67099
-			remove(key1);
a67099
-		return result;
a67099
-	}
a67099
-
a67099
 	public Iterator<Map.Entry<K2,V>> iterate(K1 key) {
a67099
 		assert k1Class.isInstance(key);
a67099
 		Map<K2,V> set = get(key);
a67099
diff --git a/aQute.libg/src/aQute/lib/collections/SortedList.java b/aQute.libg/src/aQute/lib/collections/SortedList.java
a67099
index 493d7bc..8a48a72 100644
a67099
--- a/aQute.libg/src/aQute/lib/collections/SortedList.java
a67099
+++ b/aQute.libg/src/aQute/lib/collections/SortedList.java
a67099
@@ -9,6 +9,7 @@ import java.util.List;
a67099
 import java.util.ListIterator;
a67099
 import java.util.NoSuchElementException;
a67099
 import java.util.SortedSet;
a67099
+import java.util.Spliterator;
a67099
 
a67099
 /**
a67099
  * An immutbale list that sorts objects by their natural order or through a
a67099
@@ -28,6 +29,11 @@ import java.util.SortedSet;
a67099
  */
a67099
 @SuppressWarnings("unchecked")
a67099
 public class SortedList<T> implements SortedSet<T>, List<T> {
a67099
+
a67099
+    @Override
a67099
+    public Spliterator<T> spliterator() {
a67099
+        return List.super.spliterator();
a67099
+    }
a67099
 	static SortedList< ? >		empty		= new SortedList<Object>();
a67099
 
a67099
 	final T[]					list;
a67099
diff --git a/biz.aQute.bnd/src/aQute/bnd/ant/BndTask.java b/biz.aQute.bnd/src/aQute/bnd/ant/BndTask.java
a67099
index efd43a3..9fd21fd 100644
a67099
--- a/biz.aQute.bnd/src/aQute/bnd/ant/BndTask.java
a67099
+++ b/biz.aQute.bnd/src/aQute/bnd/ant/BndTask.java
a67099
@@ -217,7 +217,7 @@ public class BndTask extends BaseTask {
a67099
 				if (inherit) {
a67099
 					Properties projectProperties = new UTF8Properties();
a67099
 					@SuppressWarnings("unchecked")
a67099
-					Hashtable<Object,Object> antProps = getProject().getProperties();
a67099
+					Hashtable<String,Object> antProps = getProject().getProperties();
a67099
 					projectProperties.putAll(antProps);
a67099
 					projectProperties.putAll(builder.getProperties());
a67099
 					builder.setProperties(projectProperties);
a67099
-- 
a67099
2.7.4
a67099