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

Fix crash with TypeScript overloaded constructors #340

Merged
merged 1 commit into from Nov 18, 2018

Conversation

alangpierce
Copy link
Owner

Fixes #334

Constructors without bodies were correctly being marked as type tokens, but the
class transformation code (to implement class fields and TS fields defined in
constructor params) was incorrectly viewing it as a real constructor. Now, when
checking if something matches the constructor keyword, we also make sure it's
not a type token.

Fixes #334

Constructors without bodies were correctly being marked as type tokens, but the
class transformation code (to implement class fields and TS fields defined in
constructor params) was incorrectly viewing it as a real constructor. Now, when
checking if something matches the constructor keyword, we also make sure it's
not a type token.
@codecov-io
Copy link

Codecov Report

Merging #340 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #340      +/-   ##
==========================================
+ Coverage   77.26%   77.26%   +<.01%     
==========================================
  Files          41       41              
  Lines        5484     5485       +1     
  Branches     1288     1289       +1     
==========================================
+ Hits         4237     4238       +1     
  Misses        878      878              
  Partials      369      369
Impacted Files Coverage Δ
src/util/getClassInfo.ts 85.12% <100%> (+0.12%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f9aca57...ea3ef5a. Read the comment docs.

@alangpierce alangpierce merged commit e460053 into master Nov 18, 2018
@alangpierce alangpierce deleted the fix-ts-overloaded-constructors branch November 18, 2018 18:19
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.

None yet

2 participants