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

add test to cover case where interface has a "this" property and a type literal #97

Merged
merged 3 commits into from
Nov 20, 2019

Conversation

Pmyl
Copy link
Collaborator

@Pmyl Pmyl commented Nov 20, 2019

This shows that #88 is not relevant, let me know if I'm doing anything wrong here

@Pmyl Pmyl requested a review from uittorio November 20, 2019 21:25
@uittorio
Copy link
Member

Yeah, I think I forgot to write the scenario correctly. There is definitely an issue. Did you try instead

interface Test {
 a: { b: 2}
 c: this
}

@Pmyl
Copy link
Collaborator Author

Pmyl commented Nov 20, 2019

Interesting, the build fails when the "this" property is declared after the type literal... I'll update the test and work on it

Pmyl added 2 commits November 20, 2019 21:42
…pe literal property and fix the problem

Problem fixed creating a getDescriptor function for type literal so that type literal don't modify the declaration node in the scope
@Pmyl
Copy link
Collaborator Author

Pmyl commented Nov 20, 2019

Done, this is now ready for review @uittorio

@uittorio
Copy link
Member

thanks!!!! I hope it was not too difficult to find the issue!

@uittorio
Copy link
Member

if you merge remember to use something like this, so it will appear on the changeling

fix(this): make sure literal type will not interfere with "this" reference

@Pmyl Pmyl merged commit fd2270b into master Nov 20, 2019
@uittorio uittorio deleted the #88_solve_type_literal_with_this_in_interface branch December 27, 2019 18:49
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 this pull request may close these issues.

2 participants