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

Optional catch binding support #405

Conversation

sanex3339
Copy link
Contributor

@sanex3339 sanex3339 commented Jan 9, 2020

Added optional catch binding support

@sanex3339 sanex3339 changed the title Optional catch binding ver 2 Optional catch binding support Jan 9, 2020
@sanex3339
Copy link
Contributor Author

@michaelficarra please check this PR

@sanex3339
Copy link
Contributor Author

@michaelficarra also can you release a new version after the merge, please.

escodegen.js Outdated
that.generateExpression(stmt.param, Precedence.Sequence, E_TTT),
')'
];
if (!stmt.param) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Always use a positive condition when there's an alternative branch. Drop the ! and swap the branches.

Copy link
Member

@michaelficarra michaelficarra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM otherwise.

@sanex3339
Copy link
Contributor Author

@michaelficarra fixed

@michaelficarra michaelficarra merged commit fb7b56f into estools:master Jan 11, 2020
@sanex3339
Copy link
Contributor Author

Thank you.

@michaelficarra can you release a new version?

@sanex3339
Copy link
Contributor Author

Ping, i really need this release

@papandreou
Copy link
Contributor

@sanex3339, you come off as quite rude with all those pings. Please be aware that this is a volunteer effort and that things take time. Why don't you publish a fork while you're waiting?

@sanex3339
Copy link
Contributor Author

@michaelficarra please,release a new version with this fix

@michaelficarra
Copy link
Member

@sanex3339 Published version 1.13.0.

@sanex3339
Copy link
Contributor Author

Thank you!

bizob2828 pushed a commit to Contrast-Security-OSS/escodegen that referenced this pull request Apr 2, 2020
* Added support for optional-catch binding

* Reverted optional catch binding condition
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.

3 participants