Skip to content

Extract dims token in correct way #8

@sabaka

Description

@sabaka

I've tried to extract it like

dims!
    :   (options{greedy=true; }:
            ({LA(1) == AT}? annotations
            | )
                lb:LBRACK^ {#lb.setType(ARRAY_DECLARATOR);} RBRACK
        )+
    ;

screen shot 2016-02-08 at 23 15 43

and

dims
    :   (options{greedy=true; }:
            ({LA(1) == AT}? annotations
            | )
                lb:LBRACK^ {#lb.setType(ARRAY_DECLARATOR);} RBRACK
        )+
    ;

screen shot 2016-02-08 at 23 18 23

but I face problem with tree structure: array declaration is not included into typespec or missed completely. I suppose it should be fixed with custom parsing structure like we use for TYPE and for lots of rules

Expected:
screen shot 2016-02-08 at 23 11 28

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions