[jboss-jira] [JBoss JIRA] (LOGTOOL-45) Avoid unnecessary calls to String#format()

David Lloyd (JIRA) jira-events at lists.jboss.org
Thu Sep 6 16:47:33 EDT 2012


     [ https://issues.jboss.org/browse/LOGTOOL-45?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

David Lloyd resolved LOGTOOL-45.
--------------------------------

    Fix Version/s: 1.1.0.Beta1
       Resolution: Done

    
> Avoid unnecessary calls to String#format()
> ------------------------------------------
>
>                 Key: LOGTOOL-45
>                 URL: https://issues.jboss.org/browse/LOGTOOL-45
>             Project: Log Tool
>          Issue Type: Feature Request
>      Security Level: Public(Everyone can see) 
>            Reporter: Gunnar Morling
>            Assignee: James Perkins
>             Fix For: 1.1.0.Beta1, 1.0.2.Final
>
>
> Generated message bundle methods always contain an invocation of {{String#format()}} also if there actually is no parameter to be replaced, e.g. like this:
> {code}
> @Override
> public final String mustNotBeNull() {
>     String result = String.format(mustNotBeNull0$str());
>     return result;
> }
> {code}
> AFAICS the invocation of {{format()}} seems superfluous, instead the String might directly be returned for performance reasons.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list