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 regexp/no-invalid-regexp rule #288

Merged
merged 3 commits into from
Aug 10, 2021
Merged

Add regexp/no-invalid-regexp rule #288

merged 3 commits into from
Aug 10, 2021

Conversation

RunDevelopment
Copy link
Collaborator

This fixes #283.

This is a branch of #287.


The implementation of the rule is quite simple. The only interesting part is the report location. While not documented, regexpp actually tells us where the syntax error occurs. The only problem is that this position isn't exact. It's off by one at times (see code comments). That being said, the error reporting is quite good.

image

@ota-meshi ota-meshi merged commit 7538e3d into master Aug 10, 2021
@ota-meshi ota-meshi deleted the issue283 branch August 10, 2021 23:47
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.

regexp/no-invalid-regexp for invalid regexes
2 participants