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 202383 - syntax highlighting of C++ lambda parameters report "undefined reference"
Summary: syntax highlighting of C++ lambda parameters report "undefined reference"
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Model (show other bugs)
Version: 7.0.1
Hardware: PC Windows XP
: P3 normal (vote)
Assignee: issues@cnd
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-21 04:18 UTC by jjeremiah
Modified: 2014-08-26 09:36 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments
screenshot (14.24 KB, image/png)
2011-09-21 04:18 UTC, jjeremiah
Details

Note You need to log in before you can comment on or make changes to this bug.
Description jjeremiah 2011-09-21 04:18:08 UTC
Created attachment 110939 [details]
screenshot

Product Version: NetBeans IDE 7.0.1 (Build 201107282000)
Java: 1.6.0_25; Java HotSpot(TM) Client VM 20.0-b11
System: Windows XP version 5.1 running on x86; Cp1252; en_NZ (nb)
C++ plugin: Version 1.14.2.1
Compiler: MinGW g++ 4.6.1

In a Netbeans C++ project, if I write:

#include <iostream>
#include <vector>
#include <algorithm>
int main()
{
    std::vector<int> container = {1,2,3,4};
    std::for_each(container.begin(),container.end(),
        [] (int x) {std::cout << "\"" << x << "\"\n";});
}

the editor highlights all occurances of x in the line with the lambda and says "unable to resolve identifier x" even though the program compiles and runs with no problem.

So the syntax highlighting of lambda parameters doesn't seem to be correct.
It's a low priority because the code compiles and runs fine.
Comment 1 nnnnnk 2011-10-06 11:59:19 UTC
We do not support C++11.