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

Regression wrt complex type positions #11431

Open
ncannasse opened this issue Dec 16, 2023 · 3 comments · May be fixed by #11433
Open

Regression wrt complex type positions #11431

ncannasse opened this issue Dec 16, 2023 · 3 comments · May be fixed by #11433

Comments

@ncannasse
Copy link
Member

In current Haxe, the position is now part of the complex type. However when creating complex type with macros we don't always have this position set, in which case it will be set to null_pos. But the problem is that if the type is not found, Haxe compiler will simply print Type not found : Name to the output without any position context, making it very hard to debug...

I can easily hit into this error by refactoring some code, without much macros involved so I think that's quite a significant issue.

@ncannasse
Copy link
Member Author

I'm not sure it's the right fix but it now gives me proper position for my refactoring. Reopening so @Simn can give a deep look maybe.

@ncannasse ncannasse reopened this Dec 16, 2023
@Simn
Copy link
Member

Simn commented Dec 16, 2023

It might be better if decode_ast_path doesn't put null_pos there in the first place. I'll take a look.

@Simn
Copy link
Member

Simn commented Dec 18, 2023

How exactly do you create these ComplexTypess? I'm trying to understand how it's possible to have pos set but not posPath.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants