Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

meta + typedef unexpected #94

Closed
eliasku opened this issue Dec 29, 2014 · 12 comments
Closed

meta + typedef unexpected #94

eliasku opened this issue Dec 29, 2014 · 12 comments

Comments

@eliasku
Copy link
Contributor

eliasku commented Dec 29, 2014

image

repro:

@:dox(hide) typedef MyInt2 = Int;

https://github.com/eliasku/horror/blob/master/tests/intellijhaxe/MetaTypedefIssue.hx

TIR: STB-7314

@EBatTiVo EBatTiVo changed the title meta + typedef unexcepted meta + typedef unexpected Feb 4, 2015
@EBatTiVo
Copy link
Contributor

EBatTiVo commented Feb 4, 2015

In haxe.bnf, typedefDeclaration doesn't include macroClassList. Might be as simple as that.

@EBatTiVo EBatTiVo added the bug label Feb 4, 2015
@as3boyan
Copy link
Contributor

The thing is that meta tags can be used almost anywhere.

@as3boyan
Copy link
Contributor

I can't generate haxe.bnf without errors, I even reverted changes made in my commit, https://github.com/EBatTiVo/intellij-haxe/commit/93abe6263300944fef69ec70f5c06c603eb0d749, @EBatTiVo please take a look, does it work for you, without errors?

@EBatTiVo
Copy link
Contributor

Just generated fine for me at HEAD: e82349e

I'm still on IDEA13: IU-135.1286 (a..k.a. version 13.1.5, I think)

@EBatTiVo
Copy link
Contributor

Just generated fine for me...

Except that the copyright notice just updated the year on every file. :(
If you update the BNF, then update the copyrights as a separate change, please.

@Simn
Copy link
Member

Simn commented Feb 13, 2015

@as3boyan: "The thing is that meta tags can be used almost anywhere."

This is not accurate. Metadata may appear in the following places:

  • before a type declaration (class, enum, typedef, abstract)
  • before class fields (in classes and abstracts as well as in structures if they use class field notation)
  • before enum fields
  • before any expression

Any number of metadata is allowed in these places. In general: when in doubt, check the official Haxe parser.

@EBatTiVo
Copy link
Contributor

I can't generate haxe.bnf without errors,

Srikanth was having the same problem. It turned out that the problem was two-fold: the last time the BNF was updated, the parser files weren't regenerated, and a new function was not overridden in the non-generated files; second, he was using a newer version of the Grammar-Kit plugin than I was.

The first problem, I fixed and have already pushed to the ClassHierarchy branch. Srikanth has fixed the issues with generating via the new Grammar-Kit plugin and those should get to ClassHierarchy today.

@as3boyan
Copy link
Contributor

@Simn Thanks for info.

@EBatTiVo I made some changes in some commit and didn't regenerated it, sorry, recently(maybe week ago) I tried to revert changes I made but still was unable to generate it

@as3boyan
Copy link
Contributor

@EBatTiVo Please pull changes to your fork, thanks

@as3boyan
Copy link
Contributor

I pushed some fixes to haxe.bnf, and made related changes in parser utils to make it work, should work I think...
762a637

@as3boyan
Copy link
Contributor

meta tags for typedef support: https://github.com/EBatTiVo/intellij-haxe/commit/9e6c363a786a69316951a793789543572d058628

I had to change typedef pin from 2 to 5, not sure, I need better understanding of pins

@eliasku
Copy link
Contributor Author

eliasku commented Feb 19, 2016

Fixed for 0.9.9
image

@eliasku eliasku closed this as completed Feb 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants