[ 
https://issues.apache.org/jira/browse/BCEL-332?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17026733#comment-17026733
 ] 

Gary D. Gregory commented on BCEL-332:
--------------------------------------

Hi [~asdf913]

Please feel free to provide a PR on GitHub at 
[https://github.com/apache/commons-bcel/]

Gary

> Separate the "ElementValuePairs" in "toString" method in 
> "org.apache.bcel.classfile.AnnotationEntry"
> ----------------------------------------------------------------------------------------------------
>
>                 Key: BCEL-332
>                 URL: https://issues.apache.org/jira/browse/BCEL-332
>             Project: Commons BCEL
>          Issue Type: Improvement
>            Reporter: Lau Ka Ho
>            Priority: Minor
>
> [https://github.com/apache/commons-bcel/blob/master/src/main/java/org/apache/bcel/classfile/AnnotationEntry.java#L136]
>  
> There are no *separator* in the list of elementValuePair(s).
> It could be better to separate them by a separator (i.e. comma)
> {code}public String toShortString() {
>     final StringBuilder result = new StringBuilder();
>     result.append("@");
>     result.append(getAnnotationType());
>     final ElementValuePair[] evPairs = getElementValuePairs();
>     if (evPairs.length > 0) {
>         result.append("(");
>         for (final ElementValuePair element : evPairs) {
>             result.append(element.toShortString());
>         }
>         result.append(")");
>     }
>     return result.toString();
> }{code}
> ||Before||Suggest|
> |{code}La/b/c//annotation/XXXX;(k1=v1k2=v2){code}|{code}@La/b/c//annotation/XXXX;(k1=v1,k2=v2){code}|



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to