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 221220 - find usages does not find implicit constructor calls.
Summary: find usages does not find implicit constructor calls.
Status: NEW
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Model (show other bugs)
Version: 7.3
Hardware: All All
: P3 normal (vote)
Assignee: Vladimir Voskresensky
URL:
Keywords:
Depends on:
Blocks: 220977
  Show dependency tree
 
Reported: 2012-11-01 08:13 UTC by Alexander Simon
Modified: 2012-12-11 06:30 UTC (History)
0 users

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 Alexander Simon 2012-11-01 08:13:01 UTC
Code example:
------------------8<---------------
class aclass {
public:aclass(){}
};

int main(int argc, char**argv) {
    aclass a;
    aclass b();
    aclass *c = new aclass();
    return 0;
}
------------------8<---------------
Call find usages of aclass.aclass().
Expected result is 3 usages.
Actual result is 1 usage.
Comment 1 Leonid Lenyashin 2012-11-01 08:26:10 UTC
Interesting.
What if there is a constructor from int:
aclass(int a) { a++; }
...

and usage like:
aclass a=5;

However, BTW, it is not something really unexpected - it is know that we do not do a good job for overloaded operators (+, <, etc) and casts ( int(...) ) if they are used implicitly.
I assume it will be better handled in the new infrastructure.