This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 209455 - [cc] Constructor completion doesn't work for types declared in different file
Summary: [cc] Constructor completion doesn't work for types declared in different file
Status: VERIFIED FIXED
Alias: None
Product: groovy
Classification: Unclassified
Component: Editor (show other bugs)
Version: 7.1
Hardware: PC Linux
: P3 normal (vote)
Assignee: Martin Janicek
URL:
Keywords:
Depends on:
Blocks: 151985
  Show dependency tree
 
Reported: 2012-03-12 10:53 UTC by Martin Janicek
Modified: 2012-04-03 13:42 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Janicek 2012-03-12 10:53:50 UTC
Current constructor completion doesn't work correctly in this situation:

- File AAA.groovy:

class AAA {
    AAA() {
    }
    
    AAA(int i) {
    }
}

- File BBB.groovy

class BBB {
    AAA aaa = new AAA|
}

=> Expected: Two constructor proposals are shown
   Actual:   Nothing is proposed

It's working correctly if we have both classes declared in the same file, but not in this situation. It also works fine for classes imported by default.
Comment 1 Martin Janicek 2012-03-13 12:50:44 UTC
Looking on Java completion, I'm changing the requirements. This should work on already imported types (that means, file BBB.groovy needs to contain also import a.AAA) + on types in the same package.

Together with fix for issue 155566 it should provide the same comfort as in java files.
Comment 2 Martin Janicek 2012-03-13 14:43:36 UTC
Fixed in: web-main #31c29b2bf4c7
Comment 3 Quality Engineering 2012-03-15 12:30:44 UTC
Integrated into 'main-golden', will be available in build *201203150400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/31c29b2bf4c7
User: Martin Janicek <mjanicek@netbeans.org>
Log: #209455 - [cc] Constructor completion doesnt work for types declared in different file
Comment 4 Vladimir Riha 2012-04-03 13:42:59 UTC
verified

Product Version: NetBeans IDE Dev (Build 201204021038)