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

Alternative to the alternative match expression for Regular Expressions #4944

Open
1 task done
thakyZ opened this issue Dec 6, 2023 · 2 comments
Open
1 task done
Labels
feature request A request for a new feature.

Comments

@thakyZ
Copy link

thakyZ commented Dec 6, 2023

Is there an existing feature request for this?

  • I have searched the existing issues before opening this feature request.

Describe the feature you would like to see.

I know that the pipe character (|) doesn't work but is there some sort of alternative for the alternative match, and if not would it be possible to add an alternative so that the alternative match can be used?

Describe the solution you'd like.

I was thinking of using another character such as %, @, !, &, or just escape the | character outright by writing \u00fc in the box explicitly, if you have to have a double escape such as \\u00fc that could work too.

Additional context to this request.

Since the rules have pipe character separating the rule definitions having an alternative character to the alternative match, would be very helpful to having regex strings.

@thakyZ thakyZ added the feature request A request for a new feature. label Dec 6, 2023
@Boy132
Copy link
Contributor

Boy132 commented Dec 7, 2023

Assuming you talk about regex in startup variable rules:
You can use ;; as separator for the rules, see #1960 (comment).
However, there is currently a bug when using ;;, see #4360.

@thakyZ
Copy link
Author

thakyZ commented Dec 16, 2023

Thank you, this does work. However, I can see there also being a problem with if you need ;; in the regex for some reason. I do not know what program or game would need syntax like that, but I am sure some day someone will bring that up. Either way, I will follow the bug report on the issue you linked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request A request for a new feature.
Projects
None yet
Development

No branches or pull requests

2 participants