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

[cpp] overload resolution for TNew #9807

Merged

Conversation

vonagam
Copy link
Member

@vonagam vonagam commented Aug 8, 2020

Adds overloading support for new in cpp.

@vonagam vonagam force-pushed the add-cpp-tnew-overloads branch 2 times, most recently from bc3e092 to 56f7b79 Compare August 8, 2020 22:01
@RealyUniqueName RealyUniqueName added this to the Backlog milestone Aug 12, 2020
@RealyUniqueName RealyUniqueName added the platform-cpp Everything related to CPP / C++ label Aug 12, 2020
@vonagam
Copy link
Member Author

vonagam commented Aug 12, 2020

Rebased on #9516 and added a test.

@Simn
Copy link
Member

Simn commented Aug 14, 2020

On a related note, I think we should try adding a tclass_field to TNew so the generators don't have to play this resolution game.

However, my bigger concern is super() calls because that would require a different AST node altogether.

@vonagam
Copy link
Member Author

vonagam commented Aug 14, 2020

Oh, right forgot about super. Thanks.

@vonagam vonagam force-pushed the add-cpp-tnew-overloads branch 2 times, most recently from f552116 to 4ccb59c Compare August 14, 2020 09:31
@vonagam
Copy link
Member Author

vonagam commented Aug 14, 2020

Ah, misinterpreted what you said in super concern as about untested effect of this PR on super resolution in cpp.
Checked if it wasn't working - it works. Added inheritance with super calls to the test just in case.

Yeah, i find it strange that haxe resolves overloads and then a generator has to do it again.

@vonagam
Copy link
Member Author

vonagam commented Dec 20, 2020

Simply rebased (now that #9516 was merged), nothing new.

@hughsando can this be given the green light?

@hughsando hughsando merged commit 86a30a7 into HaxeFoundation:development Dec 21, 2020
@hughsando
Copy link
Member

thanks - looks good

@skial skial mentioned this pull request Dec 23, 2020
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform-cpp Everything related to CPP / C++
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants