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.
Created attachment 142280 [details] screencast for test code e.g.: * class template with a getInstance() public method: template<typename T> class Singleton : boost::noncopyable { public: static T* getInstance() { ... } .... * some children SettingsManager: class SettingsManager : public Singleton<SettingsManager>, public Speaker<SettingsManagerListener> ... * and using something like this: SettingsManager::getInstance()->get(setting); ......................^ so, we have the next result "unable to resolve identifier"... But! if you use manually type cast, e.g: ((Singleton<SettingsManager>)SettingsManager)::getInstance()->get(setting); this is working fine (see screenshot) although build is successful in any case with a both variants...problem with only code-completion I also read http://stackoverflow.com/a/14914647 - BUT this settings is not available! о_О see attach If i use globally Tools -> Options -> C/C++ -> Code Assistance and/or addition to project properties "Include Directories and Headers": "unable to resolve identifier" has disappeared(notification & highlight getInstance()), but code-completion has not found still - "No Suggestions" **** also you can try with the following code: namespace intellisense { // <- *1 template<typename T> class TplClass { public: static T* staticType(){}; static void staticVoid(){}; void foo(){}; }; //... class Settings : public TplClass<Settings> { public: void show() { // check here }; private: friend class TplClass<Settings>; // <- *2 }; //... class AlsoUse { public: void show() { // check here }; }; // etc., }; works if you remove *1 or *2 otherwise it is necessary put the TplClass<Settings>:: or ((TplClass)Settings):: etc. see my video: http://youtu.be/0fW3cpdXgzo and see attach for more detail I'm using 7.4
Created attachment 142281 [details] No Suggestions
Created attachment 142282 [details] option not available
Created attachment 142283 [details] option not available -project prop
Created attachment 142284 [details] works with type cast
Created attachment 142285 [details] unable to resolve identifier
Petr, please, evaluate
Hi, Could you please check it in the latest development version (you can download it from http://bits.netbeans.org/download/trunk/nightly/latest/)? Both of your examples work fine in it, at least on Solaris. Thanks, Petr
Created attachment 142584 [details] works with a dev build yep, it works! Build 201311260002 is ok problem with 7.4 release - https://netbeans.org/downloads/ Product Version: NetBeans IDE 7.4 (Build 201310111528) Java: 1.7.0_40; Java HotSpot(TM) 64-Bit Server VM 24.0-b56 Runtime: Java(TM) SE Runtime Environment 1.7.0_40-b43 System: Windows 8 version 6.2 running on amd64; UTF-8; en_us (nb)
Thanks, great! So, I'm closing the bug as worksforme. All would be ok in the next patch.
In fact the fix is already available - you just need to update your IDE (Help->Check for Updates)
Thanks petrk! all working with patch1 - how about "Configure Code Assistance" ... as here: http://stackoverflow.com/a/14914647 why not available this option on 7.4 Patch 1 & Dev Build 201311260002 ? mark as deprecated ? or it activated in special cases ? - at least Intellisense now working fine :) ! thanks, again
Yes, there are special cases when you might configure code model "manually" in different ways (using build/exec logs, binaries with debug info, etc.). This option makes sense only for unmanaged projects (for example when project is created outside Netbeans and then imported from existing sources)
I see., thanks for reply