Bug 335029 - [code assist] no import for inner non-public interface
Summary: [code assist] no import for inner non-public interface
Status: NEW
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows XP
: P3 normal with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: Ayushman Jain CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-21 11:06 EST by Daniele Pirola CLA
Modified: 2024-05-03 15:22 EDT (History)
2 users (show)

See Also:


Attachments
Test case in a zip file (486 bytes, application/octet-stream)
2011-01-24 11:56 EST, Olivier Thomann CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Daniele Pirola CLA 2011-01-21 11:06:27 EST
Build Identifier: Build id: M20100909-0800

Suppose to have an interface like this
public interface A {
    interface B extends A {  // inner
    }
}

If in another java file you type

public class C {
...
B field;
...
}

and want to organize import automatically Eclipse doesn't fill the import and no suggestion are shown

If the inner interface B instead is marked with "public" modifier
e.g 
public interface A {
    public interface B extends A {
    }
}

Eclipse work correctly



Reproducible: Always
Comment 1 Olivier Thomann CLA 2011-01-24 11:47:54 EST
Ayushman, please investigate.
interfaces members (fields, methods or nested types) should be implicitly public. So adding public should not change anything.
Comment 2 Olivier Thomann CLA 2011-01-24 11:48:26 EST
Code assist also doesn't propose any possible completion for 'B'.
Comment 3 Olivier Thomann CLA 2011-01-24 11:49:45 EST
Of course, this is only an issue if A and C are not in the same package.
Comment 4 Olivier Thomann CLA 2011-01-24 11:56:30 EST
Created attachment 187447 [details]
Test case in a zip file
Comment 5 Daniele Pirola CLA 2013-10-01 04:13:18 EDT
news?
Comment 6 Eclipse Genie CLA 2020-05-22 13:18:52 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 7 Eclipse Genie CLA 2022-05-13 10:37:33 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 8 Eclipse Genie CLA 2024-05-03 15:22:50 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.