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 inspection of Regex options support #13354

Conversation

straight-shoota
Copy link
Member

Add methods Regex.supports_compile_options? and Regex.supports_match_options? to check whether the regex engine supports specific options.
This is a more robust and convenient alternative to checking the engine version explicitly before using options with partial support.

@straight-shoota straight-shoota self-assigned this Apr 19, 2023
@straight-shoota straight-shoota marked this pull request as draft April 19, 2023 09:52
@straight-shoota straight-shoota marked this pull request as ready for review April 19, 2023 12:06
spec/std/regex_spec.cr Outdated Show resolved Hide resolved
@straight-shoota straight-shoota added this to the 1.9.0 milestone Apr 24, 2023
@straight-shoota straight-shoota merged commit adc939a into crystal-lang:master Apr 25, 2023
@straight-shoota straight-shoota deleted the feature/regex-options-support-inspection branch April 25, 2023 07:58
@straight-shoota straight-shoota changed the title Add Regex options support inspection Add inspection for Regex options support Apr 25, 2023
@straight-shoota straight-shoota changed the title Add inspection for Regex options support Add inspection of Regex options support Apr 25, 2023
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants