File: java8_compatibility.patch

package info (click to toggle)
biojava4-live 4.2.5%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 107,220 kB
  • ctags: 31,849
  • sloc: java: 245,462; xml: 27,569; sh: 95; makefile: 72; python: 64
file content (13 lines) | stat: -rw-r--r-- 685 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
Description: Fix a test failure with Java 8
Author: Emmanuel Bourg <ebourg@apache.org>
Forwarded: no
--- a/biojava3-core/src/main/java/org/biojava3/core/sequence/location/template/AbstractLocation.java
+++ b/biojava3-core/src/main/java/org/biojava3/core/sequence/location/template/AbstractLocation.java
@@ -108,7 +108,7 @@
         this.circular = circular;
         this.betweenCompounds = betweenCompounds;
         this.accession = accession;
-        this.subLocations = Collections.unmodifiableList(subLocations);
+        this.subLocations = subLocations != null ? Collections.unmodifiableList(subLocations) : Collections.<Location>emptyList();
         assertLocation();
     }