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 244524 - Unexpected token {
Summary: Unexpected token {
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Code Model (show other bugs)
Version: 8.0.1
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: petrk
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-15 23:39 UTC by az.pengwang
Modified: 2014-08-06 11:01 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
sceen capture, nothing (9.96 KB, image/png)
2014-05-15 23:39 UTC, az.pengwang
Details

Note You need to log in before you can comment on or make changes to this bug.
Description az.pengwang 2014-05-15 23:39:37 UTC
Created attachment 147283 [details]
sceen capture, nothing

I have a compilable code like below. However, NB complains the syntax with unexpected token. As a result, it fails to parse through the rest of the file correctly.

typedef struct {
    int a;
} test_t;

typedef struct {
    test_t t;
} example_t;

#define EXAMPLE     \
    {               \
    	t : {       \
    	    a : 0   \
    	}           \
    },              \
    {               \
    	t : {       \
    	    a : 1   \
    	}           \
    }
example_t example[] = { EXAMPLE };

printf("a0 = %d, a1 = %d\n", example[0].t.a, example[1].t.a);
Comment 1 petrk 2014-07-24 18:48:52 UTC
Fixed in http://hg.netbeans.org/cnd-main/rev/895d1ceed577
Comment 2 Quality Engineering 2014-07-25 02:37:13 UTC
Integrated into 'main-silver', will be available in build *201407250001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/895d1ceed577
User: Petr Kudryavtsev <petrk@netbeans.org>
Log: Fixed #244524 - Unexpected token {