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(jsii): TypeError: Cannot read property 'getJsDocTags' of undefined #2163

Merged
merged 4 commits into from
Oct 22, 2020

Conversation

RomainMuller
Copy link
Contributor

When a trailing semicolon was left after a method body, the compiler
would choke with a TypeError due to attempting to read the JSDoc tags
of an undefined symbol.

This checks for this particular case and ignores the "class member" that
is represented by the dangling semicolon; and emits a diagnostic message
informing users the token could be removed.

Fixes #2098


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

When a trailing semicolon was left after a method body, the compiler
would choke with a `TypeError` due to attempting to read the JSDoc tags
of an `undefined` symbol.

This checks for this particular case and ignores the "class member" that
is represented by the dangling semicolon; and emits a diagnostic message
informing users the token could be removed.

Fixes #2098
@RomainMuller RomainMuller added bug This issue is a bug. effort/small Small work item – less than a day of effort module/compiler Issues affecting the JSII compiler labels Oct 22, 2020
@RomainMuller RomainMuller requested a review from a team October 22, 2020 12:56
@RomainMuller RomainMuller self-assigned this Oct 22, 2020
@mergify mergify bot added the contribution/core This is a PR that came from AWS. label Oct 22, 2020
@RomainMuller RomainMuller added this to the 🎃 October Release milestone Oct 22, 2020
@mergify
Copy link
Contributor

mergify bot commented Oct 22, 2020

Thank you for contributing! ❤️ I will now look into making sure the PR is up-to-date, then proceed to try and merge it!

@mergify mergify bot added the pr/ready-to-merge This PR is ready to be merged. label Oct 22, 2020
@mergify
Copy link
Contributor

mergify bot commented Oct 22, 2020

Merging (with squash)...

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildProject6AEA49D1-Blkkw9bQFn8A
  • Commit ID: 894956f
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify mergify bot merged commit 5d87101 into master Oct 22, 2020
@mergify mergify bot deleted the rmuller/trailing-semi branch October 22, 2020 16:06
@mergify
Copy link
Contributor

mergify bot commented Oct 22, 2020

Merging (with squash)...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. contribution/core This is a PR that came from AWS. effort/small Small work item – less than a day of effort module/compiler Issues affecting the JSII compiler
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Semicolon after method body causes "TypeError: Cannot read property 'getJsDocTags' of undefined"
3 participants