QuickTheories icon indicating copy to clipboard operation
QuickTheories copied to clipboard

Switched Lists.listOf to use new ArrayList(size) constructor to avoid memory copies. Added new ArrayListDSL which mirrors the ListDSL to offer similar flexability

Open dcapwell opened this issue 5 years ago • 0 comments

Adds a new generator for ArrayList which avoids using java.util.stream.Collector when size is know ahead of time. What I see with list generators is that a lot of time is spent growing the array (since Collector does not know the input size), so can avoid this by pre-allocating the array at the start.

dcapwell avatar Mar 20 '19 03:03 dcapwell