cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sylvain Lebresne (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-4889) Code cleanup against JDK 1.6 codestyle guide
Date Thu, 01 Nov 2012 09:57:12 GMT

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

Sylvain Lebresne commented on CASSANDRA-4889:
---------------------------------------------

{quote}
Not sure we want static imports used in cassandra
import static org.hamcrest.core.IsEqual.equalTo;
{quote}
I don't care so much about the static import, but as far as I can tell we don't use hamcrest
in the code so far, and I'm -1 on adding the dependency just to replace
{noformat}
assert Character.MAX_CODE_POINT == 0x0010ffff;
{noformat}
by some harmcrest crap.

The changes in UpdateStatement and DeleteStatement are also not the one we want. That is,
those are actually bugs, the break having be left in that code mistakenly. I've committed
the fix for that so the patch will need to be rebased. Do be careful when doing "codestyle"
fixes that when it's not a simple syntax change you do understand the code at stake to avoid
burying a bug deeper than it is like it would have been the case here.

                
> Code cleanup against JDK 1.6 codestyle guide
> --------------------------------------------
>
>                 Key: CASSANDRA-4889
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4889
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 1.3
>            Reporter: Radim Kolar
>            Assignee: Radim Kolar
>            Priority: Minor
>              Labels: codestyle
>         Attachments: cass-cleanup1.txt
>
>
> Code cleanup against jdk1.6 ruleset on lowest settings.
> problems fixed:
> extra ;
> unused imports
> incorrect if (condition is always true or always false)
> using static variable in non static way
> always true asserts

--
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

Mime
View raw message