Open Shibi-bala opened 5 months ago
Type
Description
I’m currently ooto, but as I mentioned in our last discussion, I don’t want to expand the generated types public api. We have gone to great lengths to avoid and remove code using arrays over well-encapsulated immutable types. Before examining this, it would be helpful to have examples with benchmarks of what we’re trying to resolve, as well as an analysis of the other options which might achieve the desired outcome.
@carterkozak I modified the methods to copy the array on input, which should protect our expectations around mutability. While it will cost some memory/speed, it's quite a bit more efficient than the boxed list version. Would this be ok to merge?
Before this PR
Add back optimization removed here: https://github.com/palantir/conjure-java/pull/2274#discussion_r1546622698
This will allow clients to just track primitive arrays internally which will be a nice perf improvement.
After this PR
==COMMIT_MSG== ==COMMIT_MSG==
Possible downsides?