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

scape left brace in regex. #16

Open
wants to merge 1 commit into
base: next
Choose a base branch
from

Conversation

sebastic
Copy link

Quoting perldelta:

A literal "{" should now be escaped in a pattern

If you want a literal left curly bracket (also called a left brace) in
a regular expression pattern, you should now escape it by either
preceding it with a backslash ("{") or enclosing it within square
brackets "[{]", or by using \Q; otherwise a deprecation warning will be
raised. This was first announced as forthcoming in the v5.16 release;
it will allow future extensions to the language to happen.

http://search.cpan.org/dist/perl-5.22.0/pod/perldelta.pod#A_literal_%22{%22_should_now_be_escaped_in_a_pattern

Fixes #12

Quoting perldelta:

> A literal "{" should now be escaped in a pattern
>
> If you want a literal left curly bracket (also called a left brace) in
> a regular expression pattern, you should now escape it by either
> preceding it with a backslash ("\{") or enclosing it within square
> brackets "[{]", or by using \Q; otherwise a deprecation warning will be
> raised. This was first announced as forthcoming in the v5.16 release;
> it will allow future extensions to the language to happen.

http://search.cpan.org/dist/perl-5.22.0/pod/perldelta.pod#A_literal_%22{%22_should_now_be_escaped_in_a_pattern

Fixes flackem#12
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

1 participant