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 244036

Summary: C++ 0x and 11 standard allows template closure nesting
Product: cnd Reporter: stormbyte
Component: Code CompletionAssignee: petrk
Status: RESOLVED INCOMPLETE    
Severity: normal    
Priority: P3    
Version: 8.0   
Hardware: PC   
OS: Linux   
Issue Type: DEFECT Exception Reporter:

Description stormbyte 2014-04-23 18:05:48 UTC
I have a project, and I compile it enabling -std=c++11 with g++

C++ 11 standard, now allows to close nested template definitions without causing any error, for example:

std::list<std::pair<std::string, std::string>> myList;

The problem:

Netbeans becomes crazy after this, and marks several lines below as if it had errors.

It can be workarounded by changed affected template declarations to what is needed if you don't enable 11 draft:

std::list<std::pair<std::string, std::string> > myList;

But the best solution is to somehow detect that and allow it (something like in PHP, you can select a version, the same with C++), or even allow it regardless.

Thanks
Comment 1 petrk 2014-07-23 15:35:49 UTC
What is the version of your IDE? And, please, make sure that you have set the standard to C++11 in IDE. This seems similar to bug 238889, and your line is parsed without errors in development version as well. So, maybe, you have a concrete test case where an error occurs.
Comment 2 petrk 2014-07-24 14:14:37 UTC
Changed status to incomplete because of lack of information about the bug.