You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Jonathan Ellis (JIRA)" <ji...@apache.org> on 2011/07/22 03:51:57 UTC
[jira] [Resolved] (CASSANDRA-2937) certain generic type causes
compile error in eclipse
[ 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