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 170956 - Argument guessing doesn't consider outer "this" references
Summary: Argument guessing doesn't consider outer "this" references
Status: NEW
Alias: None
Product: java
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: Dusan Balek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-26 20:13 UTC by matthies
Modified: 2009-09-04 13:45 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description matthies 2009-08-26 20:13:36 UTC
Example:

    class Test
    {
        int n;

        private class Inner
        {
            double m;
            void f1(double x) { }
            void g1(int k) { }
            void f2(Inner inner) { }
            void g2(Test test) { }
        }
    }

Within the context of Inner, the result of code completion for the four methods is:

    f1(m);
    g1(n);
    f2(this);
    g2(null);

If argument guessing can guess "g1(n)" (which effectively is "g1(Test.this.n)") and "f2(this)" (effectively "f2
(Inner.this)"), it should also be able to guess "g2(Test.this)".
Comment 1 Max Sauer 2009-09-04 13:45:13 UTC
Yes, this would be probably better. Dusane, please have a look, thanks.