You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by GitBox <gi...@apache.org> on 2019/08/25 01:39:29 UTC
[GitHub] [commons-lang] kinow commented on a change in pull request #443: Optimize string split methods: 1. Use ThreadLocal to make reuse of th…
kinow commented on a change in pull request #443: Optimize string split methods: 1. Use ThreadLocal to make reuse of th…
URL: https://github.com/apache/commons-lang/pull/443#discussion_r317378979
##########
File path: src/main/java/org/apache/commons/lang3/StringUtils.java
##########
@@ -7434,7 +7434,7 @@ public static String rotate(final String str, final int shift) {
return ArrayUtils.EMPTY_STRING_ARRAY;
}
final char[] c = str.toCharArray();
- final List<String> list = new ArrayList<>();
+ final SplitBuffer buffer = SPLIT_BUFFER_THREAD_LOCAL.get().getBuffer();
Review comment:
Leaving the variable name `list` would have reduced the changes to review I think?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services