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 241017 - False error on C++11 operator new
Summary: False error on C++11 operator new
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Model (show other bugs)
Version: 8.0
Hardware: All All
: P3 normal (vote)
Assignee: petrk
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-27 15:33 UTC by Vladimir Kvashin
Modified: 2014-01-31 02:39 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 Vladimir Kvashin 2014-01-27 15:33:29 UTC
The following correct code shows "unexpected token" error

#include <iostream>

class A {
public:
    int x;
    A(int i) {x = i;}
};

int main() {
    int a = 1;
    A* ap = new A[4]{a, a, a, a}; // unexpected token
    std::cout << ap[0].x;
    return 0;
}
Comment 1 petrk 2014-01-30 17:51:03 UTC
Fixed in http://hg.netbeans.org/cnd-main/rev/39e48ae4a448
Comment 2 Quality Engineering 2014-01-31 02:39:04 UTC
Integrated into 'main-silver', will be available in build *201401310001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/39e48ae4a448
User: Petr Kudryavtsev <petrk@netbeans.org>
Log: Fixed #241017 - False error on C++11 operator new