Optimize ListValue::new(Collection) slightly for best-case scenarios (#1565)
This commit is contained in:
1 parent
24385f28c2
commit
db031b175b
1 file changed
+1
-2
@@ -64,8 +64,7 @@ public class ListValue extends AbstractListValue implements ContainerValueInterf
|
|||||||
|
|
||||||
public ListValue(Collection<? extends Value> list)
|
public ListValue(Collection<? extends Value> list)
|
||||||
{
|
{
|
||||||
items = new ArrayList<>();
|
items = new ArrayList<>(list);
|
||||||
items.addAll(list);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected ListValue(List<Value> list)
|
protected ListValue(List<Value> list)
|
||||||
|
|||||||
Reference in new issue
Block a user