fixing incorrect default upper bound for slice. Fixes #657
This commit is contained in:
1 parent
eac4eb0537
commit
f3f8c689a8
6 files changed
+10
-7
No files matched your search
@@ -129,9 +129,9 @@ public abstract class LazyListValue extends AbstractListValue implements Iterato
|
||||
}
|
||||
|
||||
@Override
|
||||
public Value slice(long from, long to)
|
||||
public Value slice(long from, Long to)
|
||||
{
|
||||
if (to < 0) to = Integer.MAX_VALUE;
|
||||
if (to == null || to < 0) to = (long) Integer.MAX_VALUE;
|
||||
if (from < 0) from = 0;
|
||||
if (from > to)
|
||||
return ListValue.of();
|
||||
|
||||
Reference in new issue
Block a user