cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan Ellis (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (CASSANDRA-2937) certain generic type causes compile error in eclipse
Date Fri, 22 Jul 2011 01:51:57 GMT

     [ https://issues.apache.org/jira/browse/CASSANDRA-2937?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Jonathan Ellis resolved CASSANDRA-2937.
---------------------------------------

    Resolution: Fixed

committed, although in general I'm against humoring broken tools

> certain generic type causes compile error in eclipse
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2937
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2937
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Yang Yang
>            Priority: Trivial
>         Attachments: 0002-avoid-eclipse-compile-error-for-generic-type-on-Atom.patch
>
>
> the code ColumnFamily and AbstractColumnContainer uses code similar to the following
(substitute Blah with AbstractColumnContainer.DeletionInfo):
> import java.util.concurrent.atomic.AtomicReference;
> public class TestPrivateAtomicRef {
>     protected final AtomicReference<Blah> b = new AtomicReference<Blah>(new
Blah());
>     // the following form would work for eclipse
> //    protected final AtomicReference b = new AtomicReference(new Blah());
>     private static class Blah {
>     }
> }
> class Child extends TestPrivateAtomicRef {    
>     public void aaa() {
>         Child c = new Child();
>         c.b.set(
>         b.get()  //<==== eclipse shows error here
>         );
>     }
> }
> in eclipse, the above code generates compile error, but works fine under java command
line. since many people use eclipse, it's better to 
> make a temporary compromise and make DeletionInfo protected

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message